ASA SQL Reference
SQL Functions
Alphabetical list of functions
To specify 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 |
SQL/92 Vendor extension.
SQL/99 Vendor extension.
Sybase Not supported by Adaptive Server Enterprise.
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