Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 58EDD1337C84 for ; Mon, 9 May 2011 21:23:08 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 78753-02 for ; Tue, 10 May 2011 00:22:50 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from oproxy4-pub.bluehost.com (oproxy4-pub.bluehost.com [69.89.21.11]) by mail.postgresql.org (Postfix) with SMTP id CAD891337BC8 for ; Mon, 9 May 2011 21:20:03 -0300 (ADT) Received: (qmail 2166 invoked by uid 0); 10 May 2011 00:20:03 -0000 Received: from unknown (HELO host159.hostmonster.com) (74.220.207.159) by cpoproxy1.bluehost.com with SMTP; 10 May 2011 00:20:03 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=timbira.com; h=Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding:X-Identified-User; b=AsXDGNtaEVbClcENwkB0vhzOb9kAw5jNe0wsd9IYqQYHdSTIY/drpzQVOY+gTzT/T2IBewfzCGPN+jc5qtl4vw+7pR4UVaJ43tUhwx9O/b7xH5Wrp2rnaqpVhHYUUri/; Received: from 200-101-111-226.bsace705.dsl.brasiltelecom.net.br ([200.101.111.226] helo=[10.1.1.2]) by host159.hostmonster.com with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69) (envelope-from ) id 1QJagE-0008Sn-Tr; Mon, 09 May 2011 18:20:03 -0600 Message-ID: <4DC884A9.9030008@timbira.com> Date: Mon, 09 May 2011 21:19:53 -0300 From: Euler Taveira de Oliveira User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.16) Gecko/20110307 Icedove/3.0.11 MIME-Version: 1.0 To: pedro mg CC: pgsql-bugs@postgresql.org Subject: Re: BUG #6017: COPY from CSV file, WITH CSV HEADER fields order not respected References: <201105091807.p49I7P3F047244@wwwmaster.postgresql.org> In-Reply-To: <201105091807.p49I7P3F047244@wwwmaster.postgresql.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Identified-User: {1651:host159.hostmonster.com:timbirac:timbira.com} {sentby:smtp auth 200.101.111.226 authed with euler@timbira.com} X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001 X-Spam-Level: X-Archive-Number: 201105/53 X-Sequence-Number: 30192 Em 09-05-2011 15:07, pedro mg escreveu: > # COPY test1 FROM '/tmp/test1.csv' WITH CSV HEADER > Why don't you specify the columns? COPY test1 (key, c2, c1) FROM '/tmp/test1.csv' WITH CSV HEADER -- Euler Taveira de Oliveira - Timbira http://www.timbira.com.br/ PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento