On Thu, Jun 24, 2004 at 11:04:15AM +0400, sad wrote: > Now you treat NULLs as false.
Nope. NULL is neither true, nor false. It's "unknown", or "undefined". fduch=# SELECT 1 WHERE NULL::boolean; ?column? ---------- (0 rows) fduch=# SELECT 1 WHERE NOT NULL::boolean; ?column? ---------- (0 rows) So if you care, you SHOULD use IS [NOT] NULL, as Michael Glaesemann suggested. If you don't want expression to be calculated twice, use a temporary variable. -- Fduch M. Pravking ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]