pg_locks

pg_locks

The pg_locks view provides access to information about the locks held by open
transactions within Greenplum Database.

pg_locks contains one row per active lockable object,
requested lock mode, and relevant transaction. Thus, the same lockable
object may appear many times, if multiple transactions are holding or
waiting for locks on it. However, an object that currently has no locks
on it will not appear at all.

There are several distinct types of lockable objects: whole relations
(such as tables), individual pages of relations, individual tuples of
relations, transaction IDs, and general database objects. Also, the right
to extend a relation is represented as a separate lockable object.