When COPYing data to a table which uses foreign keys, if there is a reference to a key which is not there, the copy fails (as expected) but there is no error message.
Hmm. Looking at it more, seems like there is an error message when using: COPY "f" FROM '/home/lee/f.dat'; but _not_ when using: COPY "f" FROM stdin; or \copy f from f.dat This is on: PostgreSQL 7.2 on i386-unknown-freebsd4.5, compiled by GCC 2.95.3 SELECT version(); DROP TABLE p; DROP TABLE f; CREATE TABLE p ( pk int primary key ); CREATE TABLE f ( fk int references p ); COPY "p" FROM stdin; 1 2 3 4 \. COPY "f" FROM stdin; 1 2 3 4 5 \. ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org