(question) Do not get this information in
select * from pg_user ;
or using the pg_stat_activity view :
select * from pg_stat_activity;
Added:
the submission says:
One line per server process, showing the database identifier, database name, process identifier, user identifier, username , current request, request wait status, start time of the current request, the time it was started, and the client address and port number . Columns that report current request data are available if stats_command_string is not disabled. In addition, these columns are only visible if the user viewing the view is the superuser or the same as the user owning the process being reported.
You cannot filter and receive this information? which will be current users in the database, you can use the started runtime to get all requests in the last 5 minutes, for example ...
something like that.
balexandre Jan 21 '09 at 9:50 2009-01-21 09:50
source share