Postgres Проверка простаивания транзакции
select *
from pg_stat_activity
where (state = 'idle in transaction')
and xact_start is not null;
Relieved Reindeer
select *
from pg_stat_activity
where (state = 'idle in transaction')
and xact_start is not null;