V$OB_LOCKS

2024-03-05 01:54:26  Updated

Purpose

The V$OB_LOCKS view displays the current user's status for holding or requesting locks on various tables.

Note

This view is introduced since OceanBase Database V4.2.0.

Columns

Column Type Nullable? Description
SVR_IP VARCHAR2(46) NO The IP address of the OBServer node that holds or requests the lock.
SVR_PORT NUMBER(38) NO The port number of the OBServer node that holds or requests the lock.
TENANT_ID NUMBER(38) NO The ID of the tenant that holds or requests the lock.
TRANS_ID NUMBER(38) NO The ID of the transaction that holds or requests the lock.
TYPE VARCHAR2(9) NO The type of the lock. Valid values:
  • TM: indicates a table lock.
  • TX: indicates a transaction lock.
  • TR: indicates a row lock.
ID1 NUMBER NO Lock identifier 1.
  • For a table lock, the value can be a table ID or tablet ID.
  • For a transaction lock, the value is a transaction ID.
  • For a row lock, the value is a tablet ID.
ID2 VARCHAR2(553) NO Lock identifier 2.
  • For a table lock, the value is NULL.
  • For a transaction lock, the value is NULL.
  • For a row lock, the value is in the format of + .
LMODE VARCHAR2(8) NO The lock holding mode. Valid values:
  • NONE: No lock is requested.
  • SS: ROW SHARE
  • SX: ROW EXCLUSIVE
  • S: SHARE
  • SSX: SHARE ROW EXCLUSIVE
  • X: EXCLUSIVE
REQUEST VARCHAR2(8) NO The lock requesting mode. Valid values:
  • NONE: No lock is requested.
  • SS: ROW SHARE
  • SX: ROW EXCLUSIVE
  • S: SHARE
  • SSX: SHARE ROW EXCLUSIVE
  • X: EXCLUSIVE
CTIME NUMBER(38) NO The time to hold or wait for a lock, in seconds.
BLOCK NUMBER NO Indicates whether the lock requested by the current transaction is held by another transaction. Valid values:
  • 0: The requested lock is held by the current transaction instead of another transaction.
  • 1: The requested lock is held by another transaction, and the current transaction is blocked.

Contact Us