From: "Dado Feigenblatt" <[EMAIL PROTECTED]>
> I'm trying to create some tables with foreign keys.
> When I try to create a foreign key ...
>
> foreign key(seq_code) references sequences(seq_code) on update
> CASCADE on delete CASCADE,
>
> I get this message:
>
> ERROR: UNIQUE constraint matching given keys for referenced table
> "sequences" not found
>
> The problem is that the referenced field and table exist.
> Any hint?
Do you have a unique index on sequences.seq_code?
- Richard Huxton
---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?
http://www.postgresql.org/users-lounge/docs/faq.html