7.0.* and prior releases don't support using SQL-language functions
as operators. 7.1 will. However, invoking three SQL queries to add
two booleans sure seems like massive inefficiency...
regards, tom lane
On Tuesday 19 December 2000 22:11, Jeff Davis wrote:
>
> create function bool_to_int(bool) returns int as 'select 1 as result
> where $1 union select 0 as result where not $1;' language 'sql';
This is an alternative way to make the bool_to_int, but it doesn't solve your
problem unless the union