I said:
> If we want to preserve this behavior for IF et al, I don't think there
> is any practical way to apply SQL-level type coercion as I had wanted.
> We could instead make the code act like it's assigning to a plpgsql
> boolean variable --- but it will apply plpgsql's textual conversion
> met
Jan Wieck <[EMAIL PROTECTED]> writes:
> Tom Lane wrote:
>> if count(*) = 0 from Room where roomno = new.roomno then
>> raise exception ''Room % does not exist'', new.roomno;
>> end if;
>>
>> Is this really intended to be a feature?
> I have to admit it was less an intention than more a side effec
Tom Lane wrote:
Jan Wieck <[EMAIL PROTECTED]> writes:
Tom Lane wrote:
4. Use the parser's coerce_to_boolean procedure, so that nonbooleans
will be accepted in exactly the same cases where they'd be accepted
in a boolean-requiring SQL construct (such as CASE). (By default,
none are, so this isn't
Jan Wieck <[EMAIL PROTECTED]> writes:
> Tom Lane wrote:
>>> 4. Use the parser's coerce_to_boolean procedure, so that nonbooleans
>>> will be accepted in exactly the same cases where they'd be accepted
>>> in a boolean-requiring SQL construct (such as CASE). (By default,
>>> none are, so this isn't