Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> Variable in a select-script
Hallo friends
i am a beginner in pl/sql.............
how can i introduce a variable in a select-script ? for example:
BEGIN
DECLARE
now_time varchar2(2);
ColName varchar2(7);
BEGIN
now_time:=to_char(sysdate,'mi');
IF now_time='01' THEN
SpName:='wert_20';
select datum, ???now_time??? from tabel1
where datum = (select max(datum) from tabel1)
END;
END;
Got questions? Get answers over the phone at Keen.com.
Up to 100 minutes free!
http://www.keen.com
Received on Tue Jun 27 2000 - 00:00:00 CDT