1 Answer
- Newest
- Most votes
- Most comments
0
Here's a few stock queries I use to investigate
select t.relname,pid,mode,granted
from pg_locks l, pg_stat_all_tables t
where l.relation=t.relid order by relation asc;
select distinct(relation) table_id
,xid
,pid
,txn_start
,lock_mode
,trim(nspname) schema_name
,trim(relname) table_name
from svv_transactions
left join pg_class on pg_class.oid = svv_transactions.relation
join pg_namespace on pg_namespace.oid = relnamespace;
You can also use stv_locks;
answered 3 years ago
Relevant content
- asked 2 years ago
- Accepted Answerasked 2 years ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated 4 years ago
- AWS OFFICIALUpdated 3 months ago
- AWS OFFICIALUpdated 2 months ago