this feels like an embarrassingly n00bie question but... if i want to pg_dump schema foo from my database, how do i get foo into the search_path so it'll actually dump?
do i have to add it to .psqlrc? or actually change the default search_path on the service? it feels like there should be a way to do it for the pg_dump command only - as if it were a session setting in a regular psql session
I finally found it, its not a psql option, but it fits a oneliner:
PGOPTIONS=--search_path=myschema psql -h myHost -U myUser -dmyDb -p myPort.
If anybody improves it with a working version call for both unix and windows ill approve
SQL Server 2017 has a couple new stored procedures:
sp_refresh_single_snapshot_view – input param for @view_name nvarchar(261), @rgCode int
sp_refresh_snapshot_views – input param for @rgCode int
And new entries in sys.messages:
10149 – Index that has SNAPSHOT_MATERIALIZATION cannot be crea...
The underlying issue here has (hopefully) been fixed. Extra post history entries will be cleaned in the coming days.
The cause was a race condition on the hot network questions global cache:
We cache Hot Network Questions (HNQ) across the entire network. The cache expires every 15 minutes. Every...
Good to see the world continuing to struggle with solved problems over and over again based on incomplete information on Stack Overflow
> There is a chance that this will not completely eliminate the issue under high load, and we may need to add an UPDLOCK hint to the query as well. Decided to go incrementally with this, and will add the lock later if needed.
@PeterVandivier well my answer here seems partially incorrect. if someone is moved to me on it, please do
create schema foo;
create table foo.foo (i int);
given the above, i was expecting pg_dump --schema=foo to return nothing (using a different superuser account than the one i created the schema with), but i'm still getting it :-/