Specifies when an event handler is triggered.
EVENT_CONDITION( condition-name )
condition-name The condition triggering the event. The possible values are preset in the database, and are case insensitive. Each condition is valid only for certain event types. The conditions and the events for which they are valid are as follows:
Condition name | Units | Valid for... | Comments |
---|---|---|---|
DBFreePercent | n/a | DBDiskSpace | |
DBFreeSpace | MB | DBDiskSpace | |
DBSize | MB | GrowDB | |
ErrorNumber | n/a | RAISERROR | |
IdleTime | seconds | ServerIdle | |
Interval | seconds | All | Time since handler last executed |
LogFreePercent | n/a | LogDiskSpace | |
LogFreeSpace | MB | LogDiskSpace | |
LogSize | MB | GrowLog | |
RemainingValues | integer | GlobalAutoincrement | The number of remaining values |
TempFreePercent | n/a | TempDiskSpace | |
TempFreeSpace | MB | TempDiskSpace | |
TempSize | MB | GrowTemp |
INT
The EVENT_CONDITION function returns NULL when not called from an event.
SQL/2003 Vendor extension.
The following event definition uses the EVENT_CONDITION function:
CREATE EVENT LogNotifier TYPE LogDiskSpace WHERE event_condition( 'LogFreePercent' ) < 50 HANDLER BEGIN MESSAGE 'LogNotifier message' END; |
Discuss this page in DocCommentXchange. Send feedback about this page using email. |
Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1 |