Skip to content

Instantly share code, notes, and snippets.

@jbq
Created August 1, 2011 16:54
Show Gist options
  • Save jbq/1118512 to your computer and use it in GitHub Desktop.
Save jbq/1118512 to your computer and use it in GitHub Desktop.
PG queries waiting for locks
select current_query, mode, relname from pg_stat_activity inner join pg_locks on procpid = pid inner join pg_class on oid=relation where waiting = true;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment