Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> How to use bind variable
Hi,
i read that using bind variables speed application up cause reduce
parsing.
I tried to use bind variable in a stored procedure but i could not.
Take for instance,
CREATE OR REPLACE upd_sal (empno number) as
:b_empno NUMBER;
BEGIN
:b_empno:= empno; UPDATE emp SET sal = (sal +1) WHERE empno= :b_empno;
NO WAY, it doesn't work. The compilation produces errors.
How and where must I declare the bind variable???
Tia
Massimiliano
Received on Sun Mar 18 2001 - 18:24:31 CST
![]() |
![]() |