Received: from postgresql.org.org (webmail.postgresql.org [216.126.85.28]) by postgresql.org (8.11.3/8.11.1) with SMTP id f3JDxYu11831 for ; Thu, 19 Apr 2001 09:59:34 -0400 (EDT) (envelope-from pgsql-sql-owner@postgresql.org) Received: from news.tht.net (news.hub.org [216.126.91.242]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f3IAPZu13205 for ; Wed, 18 Apr 2001 06:25:48 -0400 (EDT) (envelope-from news@news.tht.net) Received: (from news@localhost) by news.tht.net (8.11.1/8.11.1) id f3IAHbJ52922 for pgsql-sql@postgresql.org; Wed, 18 Apr 2001 06:17:37 -0400 (EDT) (envelope-from news) From: Andy X-Newsgroups: comp.databases.postgresql.sql Subject: copy into serial field with auto_increment Date: Wed, 18 Apr 2001 12:16:54 +0200 Organization: i. A. d. F. Ypsilon Network GmbH Lines: 54 Message-ID: <3ADD6996.B4D2CCEA@infosys.de> Reply-To: amoeller@infosys.de Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------FD8B1669B4210469C56290AB" X-Complaints-To: scrappy@hub.org X-Mailer: Mozilla 4.75 [de] (Win98; U) X-Accept-Language: de To: pgsql-sql@postgresql.org X-Archive-Number: 200104/327 X-Sequence-Number: 2683 Dies ist eine mehrteilige Nachricht im MIME-Format. --------------FD8B1669B4210469C56290AB Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Hello, i've got a textfile of data separated by '|'. One of the fields in my table is a serial (auto_increment) field. When i import the data with the copy command i get duplicate key error. The key is the serial - field. I recognized that the copy command doesn't auto_increment the serial field. I come from mysql and pushed a 0 into the serial field. But it doesn't work. I tested it with an empty field, but it failed to. How could i make it work ?? Thanx for every help -- Andy - Kim Möller Leiter Lastminute / Pauschal - Deutschland ypsilon.net AG Leiter Entwicklungsabteilung Lastminute / Pauschal / Mietwagen - Deutschland ypsilon.net AG Tel.: (06109) - 50 50 FAX : (06109) - 50 525 eMail : amoeller@infosys.de --------------FD8B1669B4210469C56290AB Content-Type: text/x-vcard; charset=us-ascii; name="amoeller.vcf" Content-Transfer-Encoding: 7bit Content-Description: Visitenkarte für Andy Content-Disposition: attachment; filename="amoeller.vcf" begin:vcard n:Möller;Andy-Kim tel;cell:0179/2302856 tel;fax:06109 / 505 25 tel;home:06661/4526 tel;work:06109 / 505 193 x-mozilla-html:FALSE url:http://www.ypsilon.net org:i. A. d. F. Ypsilon - Network GmbH;Database - Managment & Software - Development adr:;;Vilbeler Landstr. 203;Frankfurt;Hessen;60388;Germany version:2.1 email;internet:amoeller@infosys.de fn:Andy-Kim Möller end:vcard --------------FD8B1669B4210469C56290AB--