DB2 Version 9.7 for Linux, UNIX, and Windows

AM_GET_LOCK_CHNS procedure - Retrieve lock chain information for a specific application

The AM_GET_LOCK_CHNS procedure returns lock chains for the specified application as a formatted string. A lock chain consists of all the applications that the current application is holding up or waiting for, either directly or indirectly.

Syntax

Read syntax diagramSkip visual syntax diagram
>>-AM_GET_LOCK_CHNS--(--agent_id--,--lock_chains--)------------><

The schema is SYSPROC.

Procedure parameters

agent_id
An input argument of type BIGINT that specifies the agent ID of the application whose lock chains are to be displayed.
lock_chains
An output argument of type CLOB(2M) that shows all the lock chains for the specified application.

Authorization

  • SYSMON authority
  • EXECUTE privilege on the AM_GET_LOCK_CHNS procedure.

Example

CALL SYSPROC.AM_GET_LOCK_CHNS(17,?)
  Value of output parameters
  --------------------------
  Parameter Name  : LOCK_CHAINS
  Parameter Value : >db2bp.exe (Agent ID: 17) (Auth ID: AMUSERC )

<db2bp.exe (Agent ID: 17) (Auth ID: AMUSERC )
    <db2bp.exe (Agent ID: 18) (Auth ID: AMUSERB )
        <db2bp.exe (Agent ID: 16) (Auth ID: AMUSERA )

  Return Status = 0