調(diào)用某個包里的函數(shù),看到網(wǎng)上說用select
select ******('1','2','3','4','5','6','7','8','9',10,11,12,'1','2','3','4','5','6','7','8','9','10','11') from dual;
遭遇ora錯誤
********** error:ORA-14552: cannot perform a DDL, commit or rollback inside a query or DML
ORA-06510: PL/SQL: unhandled user-defined exception
ORA-06512: at "**************", line 26
ORA-06512: at "**************", line 933
ORA-14551: cannot perform a DML operation inside a query ********* error:ORA-14552: cannot perform a DDL, commit or rollback inside a query or DML
經(jīng)查詢,函數(shù)里面有不允許select調(diào)用的操作。
選用下面的方式調(diào)用,就可以了
a1 VARCHAR2(11000);
a2 VARCHAR2(12) DEFAULT '12';
begin
a1 := ***********('finance','2','3','4','5','6','7','8','9',10,11,12,'','','','','','','','','','','11') ;
dbms_output.put_line('用戶名:'||a1);
end;
注:dbms_output.put_line('用戶名:'||a1);--輸出結(jié)果