[Last Call] Learn how to a build a cloud-first strategyRegister Now


Search through code in all triggers & store procedures: Oracle?

Posted on 2012-08-23
Medium Priority
Last Modified: 2012-08-23
I am using Oracle 9 and10.  We have hundreds of store procedures and triggers.  Is there a way to search through all of the code?  I would hate to open each one just to look for a string.

Question by:jkit001
LVL 38

Expert Comment

by:Geert Gruwez
ID: 38324976
yes: Toad

you can select what code you want to look in and what schemas you want to look
LVL 74

Accepted Solution

sdstuber earned 2000 total points
ID: 38325151
select * from dba_source where text like '%your string goes here%'
LVL 78

Expert Comment

by:slightwv (䄆 Netminder)
ID: 38325261
Small correction to the post above:

select * from dba_source where lower(text) like lower('%your string goes here%')
LVL 74

Expert Comment

ID: 38325287
no need to correct anything.

if you want an exact string search do not use LOWER

if you do not want an exact string search, then you can

also note, if you don't have access to dba_source, you could try all_source instead.
but, despite the name "all", you might miss some objects

Author Closing Comment

ID: 38325337
This works for me.  Thanks.

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.
Suggested Courses

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question