Search Postgresql Archives

Re: pg_dump and quoted identifiers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thomas Kellerer <spam_eater@xxxxxxx> writes:
> Tom Lane schrieb am 15.12.2016 um 16:20:
>> Hmm.  It might shed some light if you put "echo" in front of that
>> to see what gets printed:
>> $ echo pg_dump -d postgres -t "\"Statuses\""
>> pg_dump -d postgres -t "Statuses"

> Same here:
>   -bash-4.1$ echo pg_dump -d postgres -t "\"Statuses\""
>   pg_dump -d postgres -t "Statuses"

So no light there ... next step would be to set log_statement = all
and see what pg_dump's last few queries before failing are.
I see this with correct quoting:

2016-12-15 12:06:15.211 EST [693] LOG:  statement: SELECT c.oid
	FROM pg_catalog.pg_class c
	     LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace
	WHERE c.relkind in ('r', 'S', 'v', 'm', 'f', 'P')
	  AND c.relname ~ '^(Statuses)$'
	  AND pg_catalog.pg_table_is_visible(c.oid)

and this if I omit quotes:

2016-12-15 12:07:19.735 EST [741] LOG:  statement: SELECT c.oid
	FROM pg_catalog.pg_class c
	     LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace
	WHERE c.relkind in ('r', 'S', 'v', 'm', 'f', 'P')
	  AND c.relname ~ '^(statuses)$'
	  AND pg_catalog.pg_table_is_visible(c.oid)

(This test is on HEAD; I suppose the 'P' case is pretty new...)

			regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux