Re: FORMAT keyword not allowed in COPY ... FROM statement

Euler Taveira <[email protected]>
Newsgroups gmane.comp.db.postgresql.devel.documentation
Message-ID <CAHE3wggi2v=yHg2noWH54S9v0u=Ux-iwVUEe73x8vu2=f45WBw@mail.gmail.com>
Em sex, 22 de fev de 2019 às 06:31, PG Doc comments form
<[email protected]> escreveu:
>
> The following documentation comment has been logged on the website:
> # COPY table_name FROM '/srv/database/pg_dumps/file.csv' WITH FORMAT CSV
> HEADER DELIMITER ',' QUOTE '"' ;
> ERROR:  syntax error at or near "FORMAT"
>
Your command is wrong. Please check synopsis in [1]. Use the new
syntax (options should be inside parentheses and separated by comma).

> # COPY table_name FROM '/srv/database/pg_dumps/file.csv' WITH CSV HEADER
> DELIMITER ',' QUOTE '"' ;
> COPY 63
>
This is the old syntax (check Compatibility section at the end of [1]).


[1] https://www.postgresql.org/docs/11/sql-copy.html


-- 
   Euler Taveira                                   Timbira -
http://www.timbira.com.br/
   PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.