【发布时间】:2021-03-16 07:35:14
【问题描述】:
如何在下面的函数中添加多个例如。 l_col2 和 l_col3
l_col2 = Select sal as val2 from emp where empno = P_ID
l_col3 = Select deptno as val3 from emp where empno = P_ID
create or replace function F_MY_FUNC
(
P_ID IN number
)
return sys.odcinumberlist
as
l_coll sys.odcinumberlist;
begin
select * bulk collect into l_coll
from (
Select ename as val from emp where empno = P_ID
union all
Select ename as val from myemp where empno = P_ID
);
return l_coll;
end;
【问题讨论】:
-
您正在尝试将字符串返回到数字数组中。
-
@BarbarosÖzhan 我需要一个带参数的函数,ibb.co/ygjhGZ6 在函数中需要放在 Littlefoot 的 sql 代码下面
标签: sql oracle plsql bulkinsert