469,082 Members | 1,154 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,082 developers. It's quick & easy.

Calls to find Users and databases open...

What are the SQL commands to find who is logged on a server, what database
he/she has open, etc?

Where is this information in the help file or documentation?

Thanks,
Thomas

__________________________________________________ _______________
FREE pop-up blocking with the new MSN Toolbar – get it now!
http://toolbar.msn.com/go/onm00200415ave/direct/01/
---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Nov 23 '05 #1
2 1225
El Vie 30 Abr 2004 11:16, Thomas LeBlanc escribió:
What are the SQL commands to find who is logged on a server, what database
he/she has open, etc?

Where is this information in the help file or documentation?


select * from pg_stat_activity;

--
11:47:01 up 1 day, 17:09, 3 users, load average: 0.21, 0.65, 0.89
-----------------------------------------------------------------
Martín Marqués | select 'mmarques' || '@' || 'unl.edu.ar'
Centro de Telematica | DBA, Programador, Administrador
Universidad Nacional
del Litoral
-----------------------------------------------------------------

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to ma*******@postgresql.org so that your
message can get through to the mailing list cleanly

Nov 23 '05 #2
El Vie 30 Abr 2004 11:16, Thomas LeBlanc escribió:
What are the SQL commands to find who is logged on a server, what database
he/she has open, etc?

Where is this information in the help file or documentation?


select * from pg_stat_activity;

--
11:47:01 up 1 day, 17:09, 3 users, load average: 0.21, 0.65, 0.89
-----------------------------------------------------------------
Martín Marqués | select 'mmarques' || '@' || 'unl.edu.ar'
Centro de Telematica | DBA, Programador, Administrador
Universidad Nacional
del Litoral
-----------------------------------------------------------------

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to ma*******@postgresql.org so that your
message can get through to the mailing list cleanly

Nov 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by jwl | last post: by
12 posts views Thread by Berj | last post: by
2 posts views Thread by MUHAMAMD SALIM SHAHZAD | last post: by
reply views Thread by Thomas LeBlanc | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.