Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: "CASE when" strange

Re: "CASE when" strange

From: Barbara Boehmer <baboehme_at_hotmail.com>
Date: 20 May 2005 08:53:56 -0700
Message-ID: <1116604436.841473.175070@g14g2000cwa.googlegroups.com>


You need to either use double quotes or no quotes at all around test, not single quotes. Please see the examples below.

scott_at_ORA92> select case when sysdate is null then 'nulldate'   2 else to_char (sysdate) end as test   3 from dual
  4 /

TEST



20-MAY-05 scott_at_ORA92> select case when sysdate is null then 'nulldate'   2 else to_char (sysdate) end as "test"   3 from dual
  4 /

test



20-MAY-05 scott_at_ORA92> Received on Fri May 20 2005 - 10:53:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US