跳到主要内容

system.locks

引入或更新: v1.2.262

包含系统中锁的信息。

另请参阅: SHOW LOCKS

SELECT * FROM system.locks;

+----------+----------+-------+---------+------+------------------------+--------------------------------------+----------------------------+----------------------------+------------+
| table_id | revision | type | status | user | node | query_id | created_on | acquired_on | extra_info |
+----------+----------+-------+---------+------+------------------------+--------------------------------------+----------------------------+----------------------------+------------+
| 57 | 4517 | TABLE | HOLDING | root | xzi6pRbLUYasuA9QFB36m6 | d7989971-d5ec-4764-8e37-afe38ebc13e2 | 2023-12-13 09:56:47.295684 | 2023-12-13 09:56:47.310805 | |
| 57 | 4521 | TABLE | WAITING | zzq | xzi6pRbLUYasuA9QFB36m6 | 4bc78044-d4fc-4fe1-a5c5-ff6ab1e3e372 | 2023-12-13 09:56:48.419774 | NULL | |
+----------+----------+-------+---------+------+------------------------+--------------------------------------+----------------------------+----------------------------+------------+