Search Postgresql Archives

Re: check constraint question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Based on your first question a customer id itself is not a valid designator;
you have to specify (or link) in the group as well.

Not tested but should work:

FOREIGN KEY (template, group) REFERENCES customer (cust_id, group)

Depends on whether you want to allow cross-group associations if you need a
separate group template id.

David J.



--
View this message in context: http://postgresql.1045698.n5.nabble.com/check-constraint-question-tp5799252p5799282.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux