Navigation

Portable SQL : Statements : Access metadata : Triggers

From Linuxnetworks

Contents

[edit] ANSI

SQL-92 defines a collection of objects in INFORMATION_SCHEMA which contains the list triggers:

SELECT DISTINCT trigger_name
FROM information_schema.triggers

[edit] Firebird/Interbase

SELECT *
FROM RDB$TRIGGERS
WHERE
 RDB$SYSTEM_FLAG = 0 OR
 RDB$SYSTEM_FLAG IS NULL

[edit] MS SQL Server

SELECT name
FROM sys.triggers
WHERE is_ms_shipped = 0

[edit] MySQL

Fully compatible with SQL-92.

[edit] Oracle

SELECT trigger_name
FROM user_triggers

[edit] PostgreSQL

SELECT DISTINCT trigger_name
FROM information_schema.triggers
WHERE
 trigger_schema NOT IN ('pg_catalog', 'information_schema')

[edit] SQLite

Doesn't support retrieving the trigger names a SQL statement.

[edit] Sybase ASE

Unknown.