Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id 9DD6F8B63D8 for ; Wed, 20 Jun 2012 12:53:54 -0300 (ADT) Received: from mahout.postgresql.org ([98.129.198.123]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1ShNE7-0000nE-Q6 for pgsql-bugs@postgresql.org; Wed, 20 Jun 2012 15:53:53 +0000 Received: from [204.145.124.246] (helo=wrigleys.postgresql.org) by mahout.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1ShNDt-000089-HL for pgsql-bugs@postgresql.org; Wed, 20 Jun 2012 15:53:39 +0000 Received: from www-data by wrigleys.postgresql.org with local (Exim 4.72) (envelope-from ) id 1ShNDt-00005k-8t for pgsql-bugs@postgresql.org; Wed, 20 Jun 2012 15:53:37 +0000 Date: Wed, 20 Jun 2012 15:53:37 +0000 Message-Id: Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Subject: BUG #6701: IS NOT NULL doesn't work on complex composites To: pgsql-bugs@postgresql.org From: rikard.pavelic@zg.htnet.hr X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201206/172 X-Sequence-Number: 33399 The following bug has been logged on the website: Bug reference: 6701 Logged by: Rikard Pavelic Email address: rikard.pavelic@zg.htnet.hr PostgreSQL version: 9.1.3 Operating system: Windows 7 Description: = create type t AS (i int); create type complex as (t t, i int); create table bad(i int, c complex); insert into bad values(1, null); insert into bad values(1, ROW(null, 2)); insert into bad values(1, ROW(ROW(1), 2)); select * from bad; select * from bad where c is null; --This doesn't work as expected select * from bad where c is not null; --Fortunately a workaround select * from bad where NOT c is null;