Re: ALTER TABLE ... SET DEFAULT

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Brian McCane <bmccane(at)mccons(dot)net>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: ALTER TABLE ... SET DEFAULT
Date: 2002-04-13 03:56:55
Message-ID: 13011.1018670215@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Brian McCane <bmccane(at)mccons(dot)net> writes:
> Okay, so if I create a function as 'iscachable', it assumes that the value
> will never change, calls the function and places the value in as the
> default? This doesn't make sense to me since the 'iscacheable' only works
> inside of a transaction block.

Um ... I already told you, that is *not* the meaning of 'isCachable'.

7.3 will split this term into 'isImmutable' and 'isStable', where the
latter means approximately what you seem to expect. But the practical
behavior of existing releases is that 'isCachable' means 'fixed forever
given fixed input arguments'. If you don't like it, argue with the
code.

regards, tom lane

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message mark carew 2002-04-13 07:45:03 Re: table dump
Previous Message Tom Lane 2002-04-13 02:53:21 Re: ALTER TABLE ... SET DEFAULT