simple case syntax oddity in 8.0.0

From: Vlad <marchenko(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: simple case syntax oddity in 8.0.0
Date: 2005-02-02 15:33:51
Message-ID: cd70c68105020207337b24252a@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi there:

Postgresql 8.0.0, FreeBSD 5.3

test=> select case 0 when 0 then null else 1/0 end as test;
ERROR: division by zero

test=> select case when 0=0 then null else 1/0 end as test;
test
------

(1 row)

test=>

Postgresql 7.4.5, FreeBSD 5.3

test => select case 0 when 0 then null else 1/0 end as test;
test
------

(1 row)

test => select case when 0=0 then null else 1/0 end as test;
test
------

--
Vlad

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2005-02-02 15:37:40 Re: Does indexing help >= as well as = for integer columns?
Previous Message Martijn van Oosterhout 2005-02-02 15:29:24 Re: Does indexing help >= as well as = for integer columns?