Scenario:
I need to list all the columns in a table1
and all stored procedures that depends on those columns of this table1
. I need to populate column name and stored procedures to a new table.
I created new_table(col1, sProc)
and tried to populate the column name and respective stored procedure on this new_table
. Code I wrote is given below:
Declare
Begin
for i in (select column_name from user_tab_columns where lower(table_name) like 'table1') loop
insert into new_table
select i.column_name,
name
from user_source
where lower(text) like '%' || i.column_name || '%';
commit;
end loop;
end;
Result: The scripts run successfully but the no data is populated on this new_table.
Stress: I tried to solve it for 1 whole day and could not figure it out. Any help on this would be greately appreciated. Thank you once again.