Get resultset from oracle stored procedure

前端 未结 7 2349
生来不讨喜
生来不讨喜 2020-11-27 13:38

I\'m working on converting a stored procedure from SQL server to Oracle. This stored procedure provides a direct resultset. I mean that if you call the stored procedure in

7条回答
  •  清歌不尽
    2020-11-27 14:01

    In SQL Plus:

    SQL> var r refcursor
    SQL> set autoprint on
    SQL> exec :r := function_returning_refcursor();
    

    Replace the last line with a call to your procedure / function and the contents of the refcursor will be displayed

提交回复
热议问题