@@ -225,32 +225,21 @@ create or replace package body ut_runner is
225225 end;
226226
227227 function get_reporters_list return tt_reporters_info pipelined is
228- l_cursor sys_refcursor;
229228 l_owner varchar2(128) := upper(ut_utils.ut_owner());
230- l_results tt_reporters_info;
231- c_bulk_limit constant integer := 10;
232- l_view_name varchar2(200) := ut_metadata.get_dba_view('dba_types');
229+ l_reporters ut_reporters_info;
230+ l_result t_reporter_rec;
233231 begin
234- open l_cursor for q'[
235- SELECT
236- owner || '.' || type_name,
237- CASE
238- WHEN sys_connect_by_path(owner||'.'||type_name,',') LIKE '%]' || l_owner || q'[.UT_OUTPUT_REPORTER_BASE%'
239- THEN 'Y'
240- ELSE 'N'
241- END is_output_reporter
242- FROM ]'||l_view_name||q'[ t
243- WHERE instantiable = 'YES'
244- CONNECT BY supertype_name = PRIOR type_name AND supertype_owner = PRIOR owner
245- START WITH type_name = 'UT_REPORTER_BASE' AND owner = ']'|| l_owner || '''';
246232 loop
247- fetch l_cursor bulk collect into l_results limit c_bulk_limit;
248- for i in 1 .. l_results.count loop
249- pipe row (l_results(i));
233+ l_reporters := ut_utils.get_child_reporters( l_reporters );
234+ exit when l_reporters is null or l_reporters.count = 0;
235+ for i in 1 .. l_reporters.count loop
236+ if l_reporters(i).is_instantiable = 'Y' then
237+ l_result.reporter_object_name := l_owner||'.'||l_reporters(i).object_name;
238+ l_result.is_output_reporter := l_reporters(i).is_output_reporter;
239+ pipe row( l_result );
240+ end if;
250241 end loop;
251- exit when l_cursor%notfound;
252242 end loop;
253- close l_cursor;
254243 end;
255244
256245end ut_runner;
0 commit comments