Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • find_pk.sql /* Find Primary Key */ Oracle
  • Load testing on Oracle 19C RAC with HammerDB Oracle
  • How to connect to Oracle Database with Wallet with Python. Oracle
  • Goog notes on X$ tables Oracle
  • arch_configUOCIOTTO.ora Oracle
  • cache buffer chain latch Oracle
  • find_err.sql for finding errors from dba_errors. Oracle
  • Export Import with QUERY Oracle
  • scripts to take listener.log backup Linux/Unix
  • How do I get Oracle to automatically start when my server boots up? Oracle
  • Find average Row Length and other table size calculation. metalink notes Oracle
  • Find_planinfo.sql Oracle
  • shr1.sql for MTS or Shared server configuration Oracle
  • Important Script Method for tuning Oracle
  • create trigger syntax Oracle

crtgr.sql /* For creating trigger from data dictionary */

Posted on 02-Aug-2005 By Admin No Comments on crtgr.sql /* For creating trigger from data dictionary */

SET LONG 1000000

UNDEFINE trigger_name

SET PAGES 0

SET FEEDBACK OFF

SET LINES 132

set echo off

set numwidth 9

Set head off

set verify off

set time off

set timing off

COLUMN text FORMAT A302 word_wrapped

COLUMN spool_name NEW_VALUE spool_name NOPRINT

SELECT lower(trigger_name||’.ctr’) spool_name

FROM dba_triggers

WHERE trigger_NAME = UPPER(‘&&trigger_name’);

SPOOL &spool_name

select ‘CREATE OR REPLACE TRIGGER ‘

||DESCRIPTION

from dba_triggers

where trigger_NAME = UPPER(‘&&trigger_name’);

set lines 95

SELECT trigger_body text

FROM DBA_TRIGGERS

WHERE TRIGGER_NAME = UPPER(‘&&trigger_name’);

PROMPT /

SPOOL OFF

SET PAGES 80

SET FEEDBACK 1

set LINES 132

set echo on

Set head on

set feedback 1

set verify on

set time on

set timing on

Oracle, SQL scripts

Post navigation

Previous Post: eplan9i.sql
Next Post: Wait time tuning research

Related Posts

  • PLSQL Table Syntax 2 Oracle
  • Transfer SQL Profiles from One database to other database. Oracle
  • Difference between SYNC and AFFIRM Oracle
  • Error Handling in Proc Oracle
  • Resolving RMAN Hung Jobs Oracle
  • Implementing Listener Security Oracle

Leave a Reply Cancel reply

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

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Django (0)
  • GIT (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (394)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (1)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (343)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • tracksqltime.sql05-Mar-2026
  • Complete Git Tutorial for Beginners25-Dec-2025
  • Postgres DB user and OS user.25-Dec-2025
  • Trace a SQL session from another session using ORADEBUG30-Sep-2025
  • SQL Server Vs Oracle Architecture difference25-Jul-2025
  • SQL Server: How to see historical transactions25-Jul-2025
  • SQL Server: How to see current transactions or requests25-Jul-2025
  • T-SQL Vs PL/SQL Syntax25-Jul-2025
  • Check SQL Server edition25-Jul-2025
  • Checking SQL Server Version25-Jul-2025

Archives

  • 2026
  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Processes parameter and its dependencies on OS kernel parameters Linux/Unix
  • Drop database in Oracle 10g Oracle
  • Sort with ASCII order and Numeric Order Linux/Unix
  • Checking SQL Server Version SQL Server
  • find_idle_cpu.sql Oracle
  • Gather Stats manually using DBMS_STATS after disabling DBMS_SCHEDULER jobs as previous entry Oracle
  • before_trunc.sql Before Truncate table needs to execute following: Oracle
  • When to rebuld B-tree index Oracle

Copyright © 2026 pvmehta.com.

Powered by PressBook News WordPress theme