From a84171b078ba07ddf8f93c12ff3b7e00c4ef131c Mon Sep 17 00:00:00 2001 From: Bruce Momjian Date: Mon, 7 Apr 2008 00:51:27 +0000 Subject: [PATCH] Add documentation clarification for IS [NOT] NULL and row-valued expressions. --- doc/src/sgml/func.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index 0811a282db..097e0560ce 100644 --- a/doc/src/sgml/func.sgml +++ b/doc/src/sgml/func.sgml @@ -1,4 +1,4 @@ - + Functions and Operators @@ -344,7 +344,11 @@ IS NULL is true when the row expression itself is null or when all the row's fields are null, while IS NOT NULL is true when the row expression itself is non-null - and all the row's fields are non-null. + and all the row's fields are non-null. Because of this behavior, + IS NULL and IS NOT NULL do not always return + inverse results for row-valued expressions, i.e. a row-valued + expression that contains both NULL and non-null values will return false + for both tests. This definition conforms to the SQL standard, and is a change from the inconsistent behavior exhibited by PostgreSQL versions prior to 8.2.