CASE WHEN - Mailing list pgsql-novice

From Luiz Eduardo Cantanhede Neri
Subject CASE WHEN
Date
Msg-id 252e1f290906090753u79e37ef9kfe78091129f3d7f1@mail.gmail.com
Whole thread Raw
List pgsql-novice
Hi guys,

Just a simple question.

It's known that in SQL field = NULL is diferrent from from field IS NULL. Does the same rule applies when you use CASE .. WHEN statement ?

e.g.
CASE myField
WHEN IS NULL THEN....


From my tests, shows this sintaxt is incorrect so I replaced to
CASE myField
WHEN NULL THEN ...

this 2nd example worked so far, but I'm worried about that isn't correct way of doing it and may generate some failure returning rows with inconsistent data.
So, you guys know if using this way is a valid CASE/WHEN sentence?

I know also there's
CASE
WHEN myField IS NULL THEN ...

but I'm asking about the 2nd way to make it clear to me.

Thx

pgsql-novice by date:

Previous
From: Bruce Hyatt
Date:
Subject: Re: Yum Update Errors
Next
From: brucejhyatt@yahoo.com
Date:
Subject: Re: Yum Update Errors