Thread: Re: syntax error while using pg_dump in Postgres 8.4
CrabbeS wrote > I am trying to copy a table form one database to another by using this > command in the SQL-query builder: > pg_dump TA2000 -t from Forest -c -s | psql -h localhost postgis; pg_dump is a standalone application (i.e., something you run in a shell/command-line) and not an SQL command. Pipes (the "|" in your string) are also shell/command-line only and cannot be used where SQL is expected. David J. -- View this message in context: http://postgresql.1045698.n5.nabble.com/syntax-error-while-using-pg-dump-in-Postgres-8-4-tp5825054p5825056.html Sent from the PostgreSQL - general mailing list archive at Nabble.com.
The psql console still operates mainly at the SQL level of input. You need to use your OS's shell to run pg_dump.
Both psql and pg_dump are the same kind of application and are run in a similar fashion.
David J.
On Thu, Oct 30, 2014 at 11:13 AM, CrabbeS [via PostgreSQL] <[hidden email]> wrote:
ok That helps...
I am now trying this in psql console- think this should work... (still getting some errors- but will try to figure it out)
Thank you very much !
SarahIf you reply to this email, your message will be added to the discussion below:http://postgresql.1045698.n5.nabble.com/syntax-error-while-using-pg-dump-in-Postgres-8-4-tp5825054p5825071.html
View this message in context: Re: syntax error while using pg_dump in Postgres 8.4
Sent from the PostgreSQL - general mailing list archive at Nabble.com.