Oracle Auto Service Request (ASR) (MOSC)

MOSC Banner

I need to know if a user trigger is enabled, disabled, deleted or modified, what do I need to do?

edited Nov 16, 2016 4:01AM in Oracle Auto Service Request (ASR) (MOSC) 1 commentAnswered

I have created a user view of sys.trigger$ as follows:

CREATE OR REPLACE FORCE VIEW v_triggers_usr

(

   r_object, r_update, r_insert, r_delete, r_enabled, r_definition, r_whenclause )

AS

   SELECT t.obj#, t.update$, t.insert$, t.delete$, t.enabled, t.definition, t.whenclause

   FROM sys.trigger$ t

   WHERE t.obj# IN (

   SELECT o.obj#

   FROM sys.obj$ o

   WHERE o.type# = 12

   AND o.owner# IN (

   SELECT u.user#

   FROM sys.user$ u

   WHERE u.name = ( SELECT USER FROM DUAL ) ) )

;

I have created also a user table as follows:

CREATE TABLE ct_bit_ctl_trg (

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center