hi Louis-David,
tmp := nextval('cabin_type_id_cabin_type_seq');
seems to me you're adding a newly created key value (for which there isn't a record yet).
-- regards, jr. (j...@tailorware.org.uk) -- Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-sql