Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1awAgn-0004xG-Ta for pgsql-docs@arkaria.postgresql.org; Fri, 29 Apr 2016 15:50:46 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1awAgn-0007c1-EL for pgsql-docs@arkaria.postgresql.org; Fri, 29 Apr 2016 15:50:45 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1awAgm-0007b6-Tj for pgsql-docs@postgresql.org; Fri, 29 Apr 2016 15:50:44 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1awAgi-0001LT-SX for pgsql-docs@postgresql.org; Fri, 29 Apr 2016 15:50:44 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u3TFoc6E016987; Fri, 29 Apr 2016 11:50:38 -0400 From: Tom Lane To: "Andrei M. Eichler" cc: Kevin Grittner , "pgsql-docs@postgresql.org" Subject: Re: COPY options In-reply-to: References: Comments: In-reply-to "Andrei M. Eichler" message dated "Fri, 29 Apr 2016 12:31:37 -0300" Date: Fri, 29 Apr 2016 11:50:38 -0400 Message-ID: <16986.1461945038@sss.pgh.pa.us> X-Pg-Spam-Score: -1.2 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-docs Precedence: bulk Sender: pgsql-docs-owner@postgresql.org "Andrei M. Eichler" writes: > Following the documentation, I wrote this COPY FROM command: > COPY test_copy FROM '/mnt/disk1/files/test_file.csv' with csv header > delimiter ';' force_null date_column, date_column2, date_column3, > date_column4, date_column5 encoding 'latin1'; Which part of the documentation, exactly, inspired you to write that? Certainly not the main syntax summary for COPY, which would tell you to write something like with (format csv, header, ...); What you've got there is some variant of the pre-9.0 COPY syntax, which is documented at the bottom of the COPY reference page, and hopefully not used anywhere else. FORCE_NULL isn't mentioned in that syntax, and for that matter neither is FORCE NULL; if that works, it's accidental. regards, tom lane -- Sent via pgsql-docs mailing list (pgsql-docs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-docs