pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mark Morgan Lloyd <markMLl.pgsql-odbc@telemetry.co.uk>
To: pgsql-odbc@postgresql.org
Subject: Re: '= NULL' is not the same as 'IS NULL'
Date: Wed, 06 Sep 2006 20:40:50 +0000
Message-ID: <44FF3252.8F6A978B@telemetry.co.uk> (raw)
References: <200609061555.13070.info@kobaltwit.be>

Geert Janssens wrote:

> I tried this query directly in phpPgSQL, and indeed it returns no results. On
> the other hand, if I modify "imgname" = NULL to "imgname" IS NULL, the query
> works fine.
[...]
> Has anybody else stumbled upon this issue ?

I'm afraid so, in Joe Celko's "SQL for Smarties" book, after which I simply
accepted that that was the way SQL worked. He also comments on the IS TRUE etc.
form which I see PostgreSQL now supports, also in the relevant section of the
manual I see IS DISTINCT FROM which might help.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]



view thread (6+ messages)  latest in thread

Message-ID: <44FF3252.8F6A978B@telemetry.co.uk>
Permalink:  ../44FF3252.8F6A978B@telemetry.co.uk/
Also on:    postgresql.org/message-id/44FF3252.8F6A978B@telemetry.co.uk

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-odbc@postgresql.org
  Cc: markMLl.pgsql-odbc@telemetry.co.uk
  Subject: Re: '= NULL' is not the same as 'IS NULL'
  In-Reply-To: <44FF3252.8F6A978B@telemetry.co.uk>
  References: <200609061555.13070.info@kobaltwit.be> <44FF3252.8F6A978B@telemetry.co.uk>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox