Script to find sessions that are blocking other sessions in PostgreSQL

In this post, I am sharing a script to find sessions that are blocking other sessions in PostgreSQL. Instead of finding blocked sessions or processes, sometimes it is better to find those sessions which are the root of blocking. PostgreSQL DBA can use this script to find the cause of blocked transactions. [crayon-672680090c12e430958896/] Sep 23, … Continue reading Script to find sessions that are blocking other sessions in PostgreSQL