Re: COPY with FORMAT in Postgresql 9.x

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Humair Mohammed <humairm(at)hotmail(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: COPY with FORMAT in Postgresql 9.x
Date: 2010-12-03 15:51:50
Message-ID: 26320.1291391510@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Humair Mohammed <humairm(at)hotmail(dot)com> writes:
> Postgres 9.x provies the COPY command with new syntax with a new option called FORMAT
> http://www.postgresql.org/docs/current/static/sql-copy.html
> However when I run the following command:
> COPY dQstn FROM 'c:/bcp/postgres/dQstn.csv' WITH FORMAT csv;
> I get the following error message:
> ERROR: syntax error at or near "FORMAT"
> If I use the 8.x syntax without the FORMAT option it works fine.

This is expected: you have to use the new syntax (with parens) for
any of the new options.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Shaun McCloud 2010-12-03 16:51:02 Union Question
Previous Message Jayadevan M 2010-12-03 11:40:31 Re: Get the max viewd product_id for user_id