unique problem - Mailing list pgsql-general

From Joolz
Subject unique problem
Date
Msg-id 45568.10.0.4.254.1099322023.squirrel@webmail.arbodienst-limburg.nl
Whole thread Raw
Responses Re: unique problem
Re: unique problem
List pgsql-general
Hi everyone,

When importing a bunch of data (> 85000 rows) I get an error I can't
explain. The table into which I'm importing has a unique clause on
(code, bedrijf). The rows in the source-table are unique in this
aspect, yet when I do the import I get this "ERROR: duplicate key
violates unique constraint "werknemer_bedrijf_key".

I checked the sourcetable a number of times, even COPYd the relevant
columns to a textfile and did `uniq -d` and `uniq -D` (nothing
non-unique found), tried to delete out non-unique rows (again
nothing found).

Is there a bug in the UNIQUE behaviour? I'm running postgresql
7.4.5-2 (from backports) on a debian stable server. Is there any way
I can DEFER the unique clause, or remove it and put it back later?

Thanks!


pgsql-general by date:

Previous
From: Michael Fuhr
Date:
Subject: Re: logging queries and time used
Next
From: Neil Conway
Date:
Subject: Re: Reasoning behind process instead of thread based