Quantcast
Channel: Toad for Oracle Forum - Recent Threads
Viewing all articles
Browse latest Browse all 4385

RE: DBMS_OUTPUT.PUT_LINE

$
0
0

The problem is that you're trying to use DBMS_OUTPUT.PUT_LINE to display a variable with a SYS_REFCURSOR type, which it can't do.  Here's a simplification of your example:

DECLARE
    v_sysref    SYS_REFCURSOR;
BEGIN
    DBMS_OUTPUT.put_line(v_sysref);
END;
/

This anonymous block should produce the same error you're seeing.  If you want to display the values of the columns referenced by your cursor, you'll need to deal with each row separately.  A quick search brought up https://oracle-base.com/articles/misc/using-ref-cursors-to-return-recordsets (and other Toad-specific ones that may also help).

Hope this helps!  Good luck!
Rich


Viewing all articles
Browse latest Browse all 4385

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>