From f213131f2024bcb85aea7d2a7dfadef6a0ee1b31 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 28 Sep 2006 20:51:43 +0000 Subject: Fix IS NULL and IS NOT NULL tests on row-valued expressions to conform to the SQL spec, viz IS NULL is true if all the row's fields are null, IS NOT NULL is true if all the row's fields are not null. The former coding got this right for a limited number of cases with IS NULL (ie, those where it could disassemble a ROW constructor at parse time), but was entirely wrong for IS NOT NULL. Per report from Teodor. I desisted from changing the behavior for arrays, since on closer inspection it's not clear that there's any support for that in the SQL spec. This probably needs more consideration. --- src/include/utils/lsyscache.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/include/utils') diff --git a/src/include/utils/lsyscache.h b/src/include/utils/lsyscache.h index ad2d9e30a6..208cba3047 100644 --- a/src/include/utils/lsyscache.h +++ b/src/include/utils/lsyscache.h @@ -6,7 +6,7 @@ * Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/utils/lsyscache.h,v 1.105 2006/07/13 17:47:02 momjian Exp $ + * $PostgreSQL: pgsql/src/include/utils/lsyscache.h,v 1.106 2006/09/28 20:51:43 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -90,6 +90,7 @@ extern void get_type_io_data(Oid typid, extern char get_typstorage(Oid typid); extern Node *get_typdefault(Oid typid); extern char get_typtype(Oid typid); +extern bool type_is_rowtype(Oid typid); extern Oid get_typ_typrelid(Oid typid); extern Oid get_element_type(Oid typid); extern Oid get_array_type(Oid typid); -- cgit v1.2.1