Subject Additional SQL92 functions
Author Paul Heinz
Hi, all.

With all the talk of additional builtin functions for IB6 e.g. making the
current example UDF library available as builtins, a developer friend of
mine (currently keen on Postgresql) was wondering when/if IB6 would have the
following SQL92
functions:

COALESCE(list)
IFNULL(input,non-NULL substitute)
CASE WHEN expr THEN expr [...] ELSE expr END

COALESCE and CASE are hugely useful and can't be implemented via UDFs,
although I pointed out that some variants of IFNULL() can be implemented as
a UDF and we have done so.

I believe we wrote Null2Zero() and Null2Blank() UDFs that just return the
passed in arg back again since IB will take the inbound Null and pass it in
to your UDF either as empty string or 0.0 anyways. It was either that or we
detected that the passed in value was a NULL pointer.

I don't actually have a SQL92 decoder ring at hand, so I'm taking his word
for it that these _are_ SQL92 functions and not just (un)common extensions
that other SQL engines have. Mind you, maybe we could 'borrow' the
Postgresql implementation - my developer friend has pointed out that
Postgresql seems to have 'borrowed' the MGA design from Interbase :-)

TTFN,
Paul.