关于游标变量的测试问题
yy 2006-08-03 09:44:07 以下是一段关于游标变量的代码:
create or replace procedure test_hidden_cur(cv_results in out sys_refcursor) is
begin
open cv_results for
select id, first_name, last_name
from authors;
end test_hidden_cur;
书上说要测试这段代码,就用如下代码:
COL first_name FORMAT A12
VARIABLE x REFCURSOR
EXEC authors_sel(:x)
PRINT x
但是,我在PLSQL DEVELOPER中的SQL窗口里测试时的情况就是不行
SQL> COL first_name FORMAT A12
SQL> VARIABLE x REFCURSOR
REFCURSOR not supported
SQL> EXEC authors_sel(:x)
begin authors_sel(:x); end;
Cursor variable :X cannot be nil
x
---------
0
SQL> PRINT x
x
---------
0
SQL>
请问这是怎么回事?请问如何在调试过程中监视这样的游标变量?