Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: RE: CASE Expressions
Jonathan,
On 81714 on NT4 we get the following
SQL> select * from v$version;
BANNER
SQL>
SQL> SELECT CASE 1 WHEN 1 THEN 2 END
2 FROM DUAL;
SELECT CASE 1 WHEN 1 THEN 2 END
*
ERROR at line 1:
ORA-00923: FROM keyword not found where expected
SQL> SELECT CASE WHEN 1=1 THEN 2 END
2 FROM DUAL;
CASEWHEN1=1THEN2END
2
Under 816 I get the same results as 817. Under 815 neither query works.
For those interested, under Oracle Rdb v7.0-14 both versions of the select case work okay.
Regards,
Bruce Reardon.
-----Original Message-----
Sent: Tuesday, 24 July 2001 5:12
To: Multiple recipients of list ORACLE-L
Just a quick follow-up. The query I provided for use as a test contained a syntax error. I omitted the END keyword. I'm hanging my head in shame. The query should have been:
SELECT CASE 1 WHEN 1 THEN 2 END
FROM DUAL;
Note that Oracle9i not only supports the above, but also:
SELECT CASE WHEN 1=1 THEN 2 END
FROM DUAL;
--
Best regards,
Jonathan Gennick
Monday, July 23, 2001, 12:41:59 PM, Yuval Arnon wrote:
YA> Jonathan
YA> CASE is not supported in 8.1.7.
SQL>> select * from v$version;
YA> BANNER YA> ---------------------------------------------------------------- YA> Oracle8i Enterprise Edition Release 8.1.7.1.0 - Production
SQL>> SELECT CASE 1 WHEN 1 THEN 2
YA> 2 FROM dual; YA> SELECT CASE 1 WHEN 1 THEN 2 YA> * YA> ERROR at line 1: YA> ORA-00923: FROM keyword not found where expected
Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists --------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Mon Jul 23 2001 - 18:58:14 CDT
![]() |
![]() |