PLS-00410: duplicate fields in RECORD,TABLE or argument list are not permitted SQL> create or replace procedure p2(v_ename varchar2) is 2 v_tax_rate number(3,2):=0.03; 3 v_ename varchar2(20); 4 v_sal number(8,2); 5 v_tax number(8,2); 6 begin 7 select ename,sal into v_ename,v_sal from emp where ename=upper(v_ename); 8 dbms_output.put_line(v_ename||' '||v_sal); 9 end;
据说是形参和下面的实参类型不一样。。。改掉就好了
SQL> create or replace procedure p2(v_ename varchar2) is 2 v_tax_rate number(3,2):=0.03; 3 v_ename1 varchar2(20); 4 v_sal number(8,2); 5 v_tax number(8,2); 6 begin 7 select ename,sal,sal*v_tax_rate into v_ename1,v_sal,v_tax from emp where ename=upper(v_ename); 8 dbms_output.put_line(v_ename||' '||v_sal||' '||v_tax); 9 end; 10 /
PLS-00410: duplicate fields in RECORD,TABLE or argument list are not permittedSQL> create or replace procedure p2(v_ename varchar2) is 2 v_tax_rate number(3,2):=0.03; 3 v_ename varchar2