Suspends execution of the current program until reactivated by a WAKE statement executed on another port or a timeout expires.
PAUSE {timeout}
timeout Optional. An integer expression that evaluates to the maximum number of seconds that the port should be suspended if not reactivated. If omitted, the port can only be reactivated by executing the WAKE statement on another port.
If timeout is specified and the suspended port is not activated by a WAKE statement within the timeout period, it will reactivate itself and continue processing.
A paused port cannot miss a wake command. If one or more WAKE statements are executed while the target port is active, when next paused the port will re-wake immediately.
Consider a batch process that processes records from a queue file. The batch process might pause until a record for processing is available in the queue file and a second process that writes records into the queue file would wake the update job whenever a new record is available. This would avoid the batch process having to continually examine the queue file to see if there are records available.
WAKE statement.