21.28.5 The INFORMATION_SCHEMA INNODB_LOCK_WAITS Table

The INNODB_LOCK_WAITS table contains one or more rows for each blocked InnoDB transaction, indicating the lock it has requested and any locks that are blocking that request.

Table 21.5 INNODB_LOCK_WAITS Columns

Column nameDescription
REQUESTING_TRX_IDID of the requesting transaction.
REQUESTED_LOCK_IDID of the lock for which a transaction is waiting. Details about the lock can be found by joining with INNODB_LOCKS on LOCK_ID.
BLOCKING_TRX_IDID of the blocking transaction.
BLOCKING_LOCK_IDID of a lock held by a transaction blocking another transaction from proceeding. Details about the lock can be found by joining with INNODB_LOCKS on LOCK_ID.

Example:

mysql> SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS \G
*************************** 1. row ***************************
requesting_trx_id: 3B7
requested_lock_id: 3B7:0:306:2
  blocking_trx_id: 3B6
 blocking_lock_id: 3B6:0:306:2
1 row in set (0.00 sec)

Notes: