0

I want to identify all my stored functions which return REFCURSOR.

Is there a way to do that?

I can't find this information anywhere.

I searched in dba_functions,dba_objects,dba_arguments...

What is the (best) way to achieve it?

1 Answer 1

2

Based on a quick and simple test:

ALL_ARGUMENTS

select * from
all_arguments
where
position = 0
and data_level = 0
and argument_name is null
and data_type = 'REF CURSOR';

position 0 is the first argument of a program unit. If it does not have a name/level (data_level = 0 and argument_name is null), then it is the return argument of the function, and you are looking for sys_refcursor type, which is displayed as REF CURSOR in this view.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.