我不明白为什么该变量声明命令不起作用。你可以帮帮我吗?
SET SERVEROUTPUT ON
ACCEPT rek_pers PROMPT 'Employee name: '
ACCEPT year_sal PROMPT 'Yearly salary: '
VARIABLE vENAME VARCHAR2,vSAL NUMBER
DECLARE
:vENAME := &rek_pers;
:vSAL := &year_sal;
BEGIN
UPDATE Emp SET Emp.Sal = vSAL
Where Emp.Ename = vENAME;
COMMIT;
END;
/
我收到答案:绑定变量“vENAME”未声明
在此先感谢您的帮助!