Table variable in Oracle stored procedure

后端 未结 2 1489
臣服心动
臣服心动 2021-01-19 04:38

I\'m new to Oracle and I need to translate my SQL Server stored procedure to oracle. In SQL Server, I have function that returns a table variable.

Executing looks l

2条回答
  •  -上瘾入骨i
    2021-01-19 05:13

    ValTBL is so-called nested table. To load data in it please use BULK COLLECT option.

    Example:

    SELECT * BULK COLLECT INTO tblTSVal FROM TABLE(dbMis.fn_ag_valuesToTable(tsVal));
    

    But that is not root of the "Table or view does not exist." error problem. Please check your rights to execute dbMis.fn_ag_valuesToTable function.

    To use pl/sql function as a table is worth to read about pipelined and parallel table functions. http://docs.oracle.com/cd/E11882_01/appdev.112/e10765/pipe_paral_tbl.htm#ADDCI2140

提交回复
热议问题