BUG #5301: difference of behaviour between 8.3 and 8.4 on IS NULL with sub rows of nulls - Mailing list pgsql-bugs

From Jehan-Guillaume (ioguix) de Rorthais
Subject BUG #5301: difference of behaviour between 8.3 and 8.4 on IS NULL with sub rows of nulls
Date
Msg-id 201001291607.o0TG7HYd030019@wwwmaster.postgresql.org
Whole thread Raw
Responses Re: BUG #5301: difference of behaviour between 8.3 and 8.4 on IS NULL with sub rows of nulls
List pgsql-bugs
The following bug has been logged online:

Bug reference:      5301
Logged by:          Jehan-Guillaume (ioguix) de Rorthais
Email address:      ioguix@free.fr
PostgreSQL version: 8.3
Operating system:   Linux
Description:        difference of behaviour between 8.3 and 8.4 on IS NULL
with sub rows of nulls
Details:

Following this discussion on -hacker mailing-list:
http://archives.postgresql.org/pgsql-hackers/2010-01/msg01828.php

...as I am not sure this issue has been tracked and fixed I open a bug
report to keep it in the loop.
Please, close this bug report if it was actualy fixed in the meantime.

Behaviour in regard to IS NULL with ROWS of NULL values is inconsistent
between 8.3 and 8.4.

Here is the test case:

<~~~~~~~~~~~~~~~~~~~~~~~~
$ psql -p 5433 -U postgres -h localhost -c \
'SELECT substring(version() from 0 for 15),
  ROW(NULL,NULL) IS NULL, ROW(ROW(NULL),NULL) IS NULL;'

   substring    | ?column? | ?column?
----------------+----------+----------
 PostgreSQL 8.3 | t        | f
(1 ligne)

$ psql -p 5434 -U postgres -h localhost -c \
'SELECT substring(version() from 0 for 15),
  ROW(NULL,NULL) IS NULL, ROW(ROW(NULL),NULL) IS NULL;'

   substring    | ?column? | ?column?
----------------+----------+----------
 PostgreSQL 8.4 | t        | t
(1 ligne)
~~~~~~~~~~~~~~~~~~~~~~~~>


and here is another test case where 8.3 is inconsistent with *himself* this
time:

<~~~~~~~~~~~~~~~~~~~~~~~~~~~~
postgres=# SELECT substring(version(),12,5);
 substring
-----------
 8.3.9
(1 ligne)

postgres=# SELECT ROW(ROW(NULL),NULL) IS NULL FROM (SELECT 1) t;
 ?column?
----------
 t
(1 ligne)

postgres=# SELECT ROW(ROW(NULL),NULL) IS NULL;
 ?column?
----------
 f
(1 ligne)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~>

pgsql-bugs by date:

Previous
From: Fujii Masao
Date:
Subject: Re: unable to fail over to warm standby server
Next
From: Craig Ringer
Date:
Subject: Re: emedded SQL in C to get the record type from plpgsql