7. OpenSQL Features : Database Events : Database Event Statements : Registering to Receive a Database Event
 
Share this page                  
Registering to Receive a Database Event
To register an application to receive database events, use the REGISTER DBEVENT statement:
REGISTER DBEVENT event_name
where event_name is an existing database event. Sessions must register for each database event to be received. For each database event, the registration is in effect until the session issues the REMOVE DBEVENT statement or disconnects from the database.
The DBMS issues an error if a session attempts to register for a database event for which the session does not have register privilege.
The REGISTER DBEVENT statement can be issued from interactive or embedded SQL program.