select connectnum=count(distinct net_address)-1 from master..sysprocesses
SELECT COUNT(*) AS CONNECTIONS FROM master..sysprocesses
select connectnum=count(distinct net_address)-1 from master..sysprocesses
SELECT COUNT(*) AS CONNECTIONS FROM master..sysprocesses