问题:
Is there a command in PostgreSQL to select active connections to a given database? PostgreSQL 中是否有一个命令可以选择到给定数据库的活动连接?
psql
states that I can't drop one of my databases because there are active connections to it , so I would like to see what the connections are (and from which machines) psql
声明我不能删除我的数据库之一,因为有活动连接到它,所以我想看看连接是什么(以及来自哪些机器)
解决方案:
参考一: https://stackoom.com/question/1r7JX参考二: How to list active connections on PostgreSQL?