Oracle 视图 DBA_DML_LOCKS 官方解释,作用,如何使用详细说明

本站中文解释

(视图)

Oracle视图DBA_DML_LOCKS提供了对当前的SQL DML锁的信息的丰富表示.它显示系统中正在运行的SELECT、INSERT、UPDATE、DELETE语句中已锁定的对象信息。这个视图只显示获得锁定的语句,不会显示正在wait中的语句。

使用DBA_DML_LOCKS视图可以帮助用户实现基本的性能优化。它可以用来跟踪正在占用锁的DML操作,以帮助检测死锁和系统死循环,并得以正确地处理先前任务被锁住的情况。

官方英文解释

DBA_DML_LOCKS lists all DML locks held in the database and all outstanding requests for a DML lock.

Column Datatype NULL Description

SESSION_ID

NUMBER

Session holding or acquiring the lock

OWNER

VARCHAR2(128)

NOT NULL

Owner of the lock

NAME

VARCHAR2(128)

NOT NULL

Name of the lock

MODE_HELD

VARCHAR2(13)

The type of lock held. The values are:

  • ROWS_S (SS): row share lock

  • ROW-X (SX): row exclusive lock

  • SHARE (S): share lock

  • S/ROW-X (SSX): exclusive lock

  • NONE: lock requested but not yet obtained

MODE_REQUESTED

VARCHAR2(13)

Lock request type. The values are:

  • ROWS_S (SS): row share lock

  • ROW-X (SX): row exclusive lock

  • SHARE (S): share lock

  • S/ROW-X (SSX): exclusive lock

  • NONE: Lock identifier obtained; lock not held or requested

LAST_CONVERT

NUMBER

Time since current mode was granted

BLOCKING_OTHERS

VARCHAR2(40)

Blocking others

See Also:

Oracle Database
Concepts
for more information about lock modes for table locks


数据运维技术 » Oracle 视图 DBA_DML_LOCKS 官方解释,作用,如何使用详细说明