Search Postgresql Archives

not null across multiple columns

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

 




here is an interesting question (to me)

suppose you wanted to be certain that either one of two or more columns were present

Like in a user table, either a username or an email need to be present to create a row.

You  can't use not null because it's an either or situation.

what's the best method to accomplish this sort of constraint?



[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