Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

# of users

Status
Not open for further replies.

jscorpion

Programmer
Nov 17, 2000
40
US
Does anyone know the command to find out the number of users that are currently logged onto the SQLserver? Any information would be of great help.

Thank You,

jscorpion
 
hi,
i think u could use this queries...

this is for a server
select distinct sysl.name from master..sysprocesses sysp,master..syslogins sysl
where sysp.sid= sysl.sid

this is for a DB.
select distinct sysl.name from master..sysprocesses sysp,master..syslogins sysl, sysdatabases sysd
where sysp.sid= sysl.sid and sysd.dbid = sysp.dbid and sysd.dbid = 7

Sunil
 
thanks for your reply

Do you know if this command would work in Centura SQLbase or do you know the command for the SQLbase?
 
I'm not familiar with SQLBase. Check the documentation for a method to count current connections. Terry L. Broadbent - DBA
Computing Links:
faq183-874 contains "Suggestions for Getting Quick and Appropriate Answers" to your questions.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top