Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id DC1D5475CEE for ; Tue, 28 Jan 2003 08:30:31 -0500 (EST) Received: from email03.aon.at (WARSL402PIP6.highway.telekom.at [195.3.96.93]) by postgresql.org (Postfix) with SMTP id B0EF5475AE4 for ; Tue, 28 Jan 2003 08:30:29 -0500 (EST) Received: (qmail 219060 invoked from network); 28 Jan 2003 13:30:31 -0000 Received: from m214p017.dipool.highway.telekom.at (HELO aon.at) ([62.46.16.177]) (envelope-sender ) by qmail3rs.highway.telekom.at (qmail-ldap-1.03) with SMTP for ; 28 Jan 2003 13:30:31 -0000 Message-ID: <3E368509.9050200@aon.at> Date: Tue, 28 Jan 2003 14:26:33 +0100 From: Oliver Vecernik User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:1.0.0) Gecko/20020623 Debian/1.0.0-0.woody.1 X-Accept-Language: de, de-de MIME-Version: 1.0 To: pgsql-sql Subject: import error Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/431 X-Sequence-Number: 11296 Hi all! I'm trying to import a text file from Suunto Dive Manager. I've got following table structure: CREATE TABLE dives ( id int, dive_number int, dive_date date, time_of_day time, series int, dc_dive_number int, dive_time int, surface_interval int, max_depth float, mean_depth float, dc_type int, dc_serial_number int, dc_personal_data text, dc_sample_rate int, dc_altitude_mode int, dc_personal_mode int, solution_time_adj int, modified int, location text, site text, weather text, water_visibility text, air_temp int, water_temp int, water_temp_at_end int, partner text, dive_master text, boat_name text, cylinder_desc text, cylinder_size float, cylinder_units_code int, cylinder_work_pressure float, cylinder_start_pressure float, cylinder_end_pressure int, sac_rate float, sac_units int, user_field_1 text, user_field_2 text, user_field_3 text, user_field_4 text, user_field_5 text, weight int, oxygen_percent int, olf_percent int, otu_flag int ); Data is structured as follows: 1,1,"07.08.2001","11:35",1,1,2220,0,6.0,0.0,12,0,"",20,0,0,0,1,"Sarigerme","Asche Bucht","wolkenlos",">20m",35,0,30,"","Mehmet Semerkant","","",0.00000,1,0.0000,0.0000,0,0.0000,0,"","","","","",12,0,0,0 My import gives following error: sport=# copy dives from '/var/n/tmp/ov.CSV' delimiters ','; ": can't parse "ne 1, pg_atoi: error in "0 My first thought was that the date and time is wrong (because it's the only "0), but even after removing it for a test results in the same error. How can I find out, which field exactly causes this error? My PostgreSQL version is (on Debian/Woody): sport=# select version(); version --------------------------------------------------------------- PostgreSQL 7.2.1 on i686-pc-linux-gnu, compiled by GCC 2.95.4 (1 row) Regards, Oliver -- VECERNIK Datenerfassungssysteme A-2560 Hernstein, Hofkogelgasse 17 Tel.: +43 2633 47530, Fax: DW 50 http://members.aon.at/vecernik