COPY - Ignore Problems

From: Ron St-Pierre <rstpierre(at)syscor(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: COPY - Ignore Problems
Date: 2003-12-22 23:47:36
Message-ID: 3FE78298.2030104@syscor.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I wish to insert data into a table from a very large text file (from a
cron script) using COPY. However if the lName (TEXT), fName(TEXT),
workDate(DATE) already exist I don't want to insert data and just want
to move onto the next record. Is there any way I can tell my bash
script/COPY to ignore the case where the unique constraint exists
(lName,fName,workDate), and move on to the next record?

ps 7.4, debian stable
TIA
Ron

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dann Corbit 2003-12-23 00:03:10 Re: COPY - Ignore Problems
Previous Message Alvaro Herrera 2003-12-22 23:43:52 Re: Parser: parse error - please help...