Michael Glaesemann <[EMAIL PROTECTED]> writes:
> In both cases, the CHECK constraint uses a function that is stable or 
> volatile. It was suggested that functions used in CHECK constraints be 
> restricted to immutable,

This seems reasonable to me.  I'm a bit surprised we do not have such a
check already.

Of course, a user could easily get into the sort of situation you
describe anyway, just by lying about the volatility labeling of a
user-defined function.  But at least we could say it was his fault
then ;-)

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
      joining column's datatypes do not match

Reply via email to