Is it possible to have a unique constraint such that one particular column has a value only once?
For instance
-----------------------
name | price | default
-----------------------
XYZ | 20 | TRUE
-----------------------
XYZ | 30 | FALSE
-----------------------
XYZ | 40 | FALSE
-----------------------
ABC | 50 | FALSE
-----------------------
So in above table, for a particular name
value, default
value can be TRUE only once. And will have a unique constraint on name & price columns.
Is this possible?