|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A trigger execution context holds information that is available from the context of a trigger invocation.
IBM Corp. reserves the right to change, rename, or remove this interface at any time.
Field Summary | |
static int |
DELETE_EVENT
Return value from getEventType() for a delete trigger. |
static int |
INSERT_EVENT
Return value from getEventType() for an insert trigger. |
static int |
UPDATE_EVENT
Return value from getEventType() for an update trigger. |
Method Summary | |
java.lang.String |
getEventStatementText()
Get the text of the statement that caused the trigger to fire. |
int |
getEventType()
Get the type for the event that caused the trigger to fire. |
java.lang.String[] |
getModifiedColumns()
Get the columns that have been modified by the statement that caused this trigger to fire. |
java.sql.ResultSet |
getNewRow()
Like getNewRowSet(), but returns a result set positioned on the first row of the after (new) result set. |
java.sql.ResultSet |
getNewRowSet()
Returns a result set of the new (after) images of the changed rows. |
java.sql.ResultSet |
getOldRow()
Like getOldRowSet(), but returns a result set positioned on the first row of the before (old) result set. |
java.sql.ResultSet |
getOldRowSet()
Returns a result set of the old (before) images of the changed rows. |
UUID |
getTargetTableId()
Get the target table UUID upon which the trigger event is declared. |
java.lang.String |
getTargetTableName()
Get the target table name upon which the trigger event is declared. |
boolean |
wasColumnModified(int columnNumber)
Find out if a column was changed, by column number |
boolean |
wasColumnModified(java.lang.String columnName)
Find out if a column was changed, by column name. |
Field Detail |
public static final int UPDATE_EVENT
public static final int DELETE_EVENT
public static final int INSERT_EVENT
Method Detail |
public java.lang.String getTargetTableName()
public UUID getTargetTableId()
public int getEventType()
public java.lang.String getEventStatementText()
public java.lang.String[] getModifiedColumns()
public boolean wasColumnModified(java.lang.String columnName)
columnName
- the column to check
public boolean wasColumnModified(int columnNumber)
columnNumber
- the column to check
public java.sql.ResultSet getOldRowSet() throws java.sql.SQLException
Will return null if the call is inapplicable for the trigger that is currently executing. For example, will return null if called during a the firing of an INSERT trigger.
java.sql.SQLException
- if called after the triggering event has
completedpublic java.sql.ResultSet getNewRowSet() throws java.sql.SQLException
Will return null if the call is inapplicable for the trigger that is currently executing. For example, will return null if called during the firing of a DELETE trigger.
java.sql.SQLException
- if called after the triggering event has
completedpublic java.sql.ResultSet getOldRow() throws java.sql.SQLException
Will return null if the call is inapplicable for the trigger that is currently executing. For example, will return null if called during a the firing of an INSERT trigger.
java.sql.SQLException
- if called after the triggering event has
completedpublic java.sql.ResultSet getNewRow() throws java.sql.SQLException
Will return null if the call is inapplicable for the trigger that is currently executing. For example, will return null if called during the firing of a DELETE trigger.
java.sql.SQLException
- if called after the triggering event has
completed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |