A script-enabled browser is required for this page to function properly.

Creating a Timer

You can create a timer by using the CREATE_TIMER Built-in subprogram.

CREATE_TIMER(timer_name, milliseconds, iterate);

where:

timer_name

Specifies the timer name of up to 30 alphanumeric characters. The name must begin with an alphabetic character. The datatype of the name is CHAR.

milliseconds

Specifies the duration of the timer in milliseconds. The range of values allowed for this parameter is 1 to 2147483648 milliseconds. Values > 2147483648 will be rounded down to 2147483648. Note that only positive numbers are allowed. The datatype of the parameter is NUMBER. See Restrictions below for more information.

iterate

Specifies whether the timer should repeat or not upon expiration. Takes the following constants as arguments:

REPEAT Indicates that the timer should repeat upon expiration. Default.

NO_REPEAT Indicates that the timer should not repeat upon expiration, but is to be used once only, until explicitly called again.

Creating a timer: Examples

/* Create a repeating timer that expires every hour */
DECLARE
hour_timer TIMER;
one_hour NUMBER(7):=3600000;
BEGIN
hour_timer:= CREATE_TIMER('alarm',one_hour,REPEAT);
END;


Modifying a timer programmatically

Deleting a timer

About timer usage rules

Responding to multiple timers

When-Timer-Expired Trigger

CREATE TIMER Built-in