|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Oracle Error PLS-00103 Encountered the sysbol "CASE"
Hi All,
I am trying compile a procedure with the following statement. select (CASE WHEN 10 <= 2 THEN 10 ELSE 20 END) INTO out_val FROM DUAL; But it is throughing an Error with the following message PLS-00103 Encountered the sysbol "CASE" when expecting one of the following: .....etc. I am using Oracle 8.1.7.4. If Run that statement at SQL > prompt in SQL* PLUS it is working fine. Thanks for your help Last edited by subbu : January 15th, 2004 at 12:35 PM. |
|
#2
|
|||
|
|||
|
Can you post your PL/SQL block?
__________________
El éxito consiste en una serie de pequeñas victorias día a día MySQL, MS SQL, MS ACCESS, Oracle Database Manager - http://victorpendleton.net/products/psdviewer.html |
|
#3
|
|||
|
|||
|
following code is working fine in oracle9i
declare out_val number; begin select (CASE WHEN 10 <= 2 THEN 10 ELSE 20 END) INTO out_val FROM DUAL; dbms_output.put_line(out_val); end; i am unable to test it in oracle8i. sorry for that. |
|
#4
|
|||
|
|||
|
This variant of the CASE expression is definitely available with Oracle 8.1.7 SQL, but as you experienced it is not available with 8.1.7 PL/SQL.
Cheers, Dan |
|
#5
|
||||
|
||||
|
Are you "translating" from MsSQL or do you dislike "decode"?
|
![]() |
| Viewing: Dev Shed Forums > Databases > Oracle Development > Oracle Error PLS-00103 Encountered the sysbol "CASE" |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|