Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Oracle Script For Menu
set echo off
ACCEPT VAL PROMPT 'ENTER CHOICE :'
begin
if &val = 1 then
activity1
elsif &val = 2 then
activity2
end;
/
Please note there is SQL and PL/SQL. SQL doesn't have procedural constructs. So in ordinary SQL if then else is not possible.
-- Sybrand Bakker Senior Oracle DBAReceived on Fri Jun 10 2005 - 08:07:39 CDT