Reputation: 3546
I need a sql statement that retrieves the names of all triggers currently setup in the database. I am using Oracle SQL Developer version 1.5.5, with java version 1.7.
Something like this:
select OBJECT_NAME from OBJECTS where OBJECT_TYPE = 'Trigger'
Upvotes: 0
Views: 6729
Reputation: 191265
What you have is pretty close:
select owner, object_name
from all_objects
where object_type = 'TRIGGER'
Or more usefully:
select owner, trigger_name, table_owner, table_name, triggering_event
from all_triggers
all_triggers
has other columns to give you more information that all_objects
does, like when the trigger fires. You can get more information about this and other useful data dictionary view in the documentation.
Upvotes: 4