> It hit me today that a 1:n relationship can't be implemented just by a > single foreign key constraint if n>0. I must have been sleeping very > deeply not to notice this. > > E.g. if there is a table "list" and another table "list_item" and the > relationship can be described as "every list has at least one > list_item" (and every list_item can only be part of one list, but > this is trivial).
<duck> BTW: If every list_item could be part of any number (>0) of lists, you get a n:m relationship with a join table and then the issue that each list_item has to belong to at least one list arises as well. Maybe there should also be a standard solution documented somewhere for this case, too. </duck> Sincerely, Wolfgang -- Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-sql