Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • True Session Wait Activity in Oracle 10g Verygood Oracle
  • on IBM-AIX for display Linux/Unix
  • rm_backup_arch_file.ksh Linux/Unix
  • switchlogfile.sh Linux/Unix
  • Find execution plan from dba_hist_sql_plan for a specific SQL_ID and PLAN_HASH_VALUE fplan.sql Oracle
  • segment_wise_space.sql segspace.sql Segment wise space usage (allocated and used) Oracle
  • Temporary tablespace explaination Oracle
  • 284785.1 How to check RAC Option is currently linked into the Oracle Binary Oracle
  • Drop database in Oracle 10g Oracle
  • ORA-01220 Oracle
  • New Latest Param.sql for finding all hidden parameters also Oracle
  • Transfer SQL Profiles from One database to other database. Oracle
  • Oracle Connections expire_time and firewall Oracle
  • Oracle10g – Using SQLAccess Advisor (DBMS_ADVISOR) with the Automatic Workload Repository Oracle
  • adding new line after specific pattern using sed Linux/Unix

find_string_in_database.sql

Posted on 02-Jun-2009 By Admin No Comments on find_string_in_database.sql

set lines 120 pages 2000

accept pvm prompt “Enter The String You Want to Search -> ”

select distinct owner, name, type from dba_source where

instr(upper(text), upper(‘&pvm’)) != 0 ;

set serveroutput on

DECLARE

CURSOR cur_triggers IS

SELECT owner, trigger_name, table_name, trigger_body

FROM dba_triggers;

v_position INTEGER;

BEGIN

DBMS_OUTPUT.ENABLE(NULL);

DBMS_OUTPUT.PUT_LINE(‘OWNER TABLE NAME TRIGGER NAME ‘);

DBMS_OUTPUT.PUT_LINE(‘===================================================================================================’)

;

FOR pvm1 IN cur_triggers LOOP

v_position := INSTR(upper(pvm1.trigger_body), upper(‘&pvm’));

IF v_position > 0 THEN

DBMS_OUTPUT.PUT_LINE(rpad(pvm1.owner,30, ‘ ‘) || ‘ ‘|| rpad(pvm1.table_name, 30, ‘ ‘) || ‘ ‘|| rpad(pvm1.trigger_name,

30, ‘ ‘));

END IF;

END LOOP;

END;

/

Oracle, SQL scripts

Post navigation

Previous Post: How to Make Trace Files Created by Oracle Readable by All Users ?
Next Post: check_copy_progress.sh

Related Posts

  • Index Range Scan Oracle
  • All Hints for Oracle Databases Oracle
  • myfile Oracle
  • Find all users who have DML privileges Oracle
  • RMAN : Consistent Backup, Restore and Recovery using RMAN Oracle
  • proc.sql Oracle

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • load SPM baseline from cursor cache05-Jun-2025
  • Drop all SPM baselines for SQL handle05-Jun-2025
  • Load SPM baseline from AWR05-Jun-2025
  • Drop specific SQL plan baseline – spm05-Jun-2025
  • findinfo.sql (SQL for getting CPU and Active session info)27-May-2025
  • SQL Tracker by SID sqltrackerbysid.sql22-Apr-2025
  • How to connect to Oracle Database with Wallet with Python.21-Mar-2025
  • JSON/XML Types in Oracle18-Mar-2025
  • CPU Core related projections12-Mar-2025
  • Exadata Basics10-Dec-2024

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Identical Dblink Issue… Oracle
  • Find execution plan from dba_hist_sql_plan for a specific SQL_ID and PLAN_HASH_VALUE fplan.sql Oracle
  • moving lob object to other tablespace lob_mvmt.sql Oracle
  • Free conference number from http://www.freeconference.com Oracle
  • find checksum of a file. Linux/Unix
  • Looping for remote servers and find its database from oratab file. Linux/Unix
  • Metalink Note: Note:250655.1 : ADDM Basics USING THE AUTOMATIC DATABASE DIAGNOSTIC MONITOR Oracle
  • perf_today.sql Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme