DB2 Version 10.1 for Linux, UNIX, and Windows

MON_INCREMENT_INTERVAL_ID procedure - increment the monitoring interval

The MON_INCREMENT_INTERVAL_ID procedure increments the monitoring interval by 1 and returns the new value in the output argument. The current monitoring interval is indicated by the MON_INTERVAL_ID database global variable.

Syntax

Read syntax diagramSkip visual syntax diagram
>>-MON_INTERVAL_INCREMENT_ID--(--new_id--)---------------------><

The schema is SYSPROC.

Procedure parameters

new_id
An output argument of type BIGINT that returns the new monitoring interval.

Authorization

One of the following authorities is required to execute the routine:
  • EXECUTE privilege on the routine
  • DATAACCESS authority
  • DBADM authority
  • SQLADM authority

Default PUBLIC privilege

None

Usage Notes

As an autonomous procedure, MON_INCREMENT_INTERVAL_ID executes in its own transaction scope.

When the value of MON_INTERVAL_ID reaches the maximum BIGINT value, it is cycled back to 1.

Example

To increment the interval ID and return the new value in the argument. This example assumes that MY_ID is a previously created session global variable.
CALL SYSPROC.MON_INCREMENT_INTERVAL_ID(MY_ID)