I would like to search through all of my procedures packages and functions for a certain phrase.
Since it is possible to retrieve the code for compiled procedures using toad I assume that the full text is stored in some data dictionary table. Does anyone know where that would be?
Thanks a lot
You can find the package body in all_source view. SELECT * FROM all_source WHERE TYPE = 'PACKAGE BODY' AND name = '<your package name>' ORDER BY line; I think you are probably trying to search using function name and not able to find it.
The Oracle INSTR function is used to search string for substring and find the location of the substring in the string. If a substring that is equal to substring is found, then the function returns an integer indicating the position of the first character of this substring.
You can do something like
SELECT name, line, text FROM dba_source WHERE upper(text) like upper('%<<your_phrase>>%') escape '\'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With