COALESCE bug
Hy,
my PostgreSQL 8.0.0 on i686-pc-mingw32, compiled by GCC gcc.exe (GCC) 3.4.2
crashes when
SELECT * FROM pg_stat_activity WHERE datname=COALESCE(NULL, NULL);
I had an mistake in a stored procedure so COALESCE got 2 NULL values but
a crash is not nice here ;-)
workaround :
SELECT * FROM pg_stat_activity WHERE datname=COALESCE(NULL, NULL, '');
so COALESCE has one nice param to return.
Daniel
(Windows)
On Mon, Oct 10, 2005 at 03:56:10PM +0200, Daniel Schuchardt wrote:
my PostgreSQL 8.0.0 on i686-pc-mingw32, compiled by GCC gcc.exe (GCC) 3.4.2
crashes when
SELECT * FROM pg_stat_activity WHERE datname=COALESCE(NULL, NULL);
Already reported and fixed as of 8.0.3; consider upgrading (8.0.4
is the latest).
http://archives.postgresql.org/pgsql-bugs/2005-04/msg00058.php
http://archives.postgresql.org/pgsql-committers/2005-04/msg00134.php
--
Michael Fuhr