Search Postgresql Archives

Re: gexec from command prompt?

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

 



On Thu, Jan 12, 2023 at 10:34 AM Pavel Stehule <pavel.stehule@xxxxxxxxx> wrote:

čt 12. 1. 2023 v 18:25 odesílatel Ron <ronljohnsonjr@xxxxxxxxx> napsal:

Removing "\\exec" from the statement, and appending -c "\\gexec" to the psql
command technically worked, but did not run the commands.

I don't know why, but \g* commands don't work from the -c option. But in this case it is not necessary


Well, the -c option states:

command must be either a command string that is completely parsable by the server (i.e., it contains no psql-specific features), or a single backslash command. Thus you cannot mix SQL and psql meta-commands within a -c option.

Thus any meta-command that interacts with server-parsed SQL is rendered useless in -c

David J.


[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 Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux