You can use also the sysusers view:
select * from sysusers
You can read the sybase help for a list of all system view.
Main Topics
Browse All TopicsHi,
I want to find out the list of all users in the database.
Please let me know how it should be done.
Also , what does suid mean in sysusers.
Thanks
Chitra.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
To get list of all users in database
use database
select name from sysusers where udi<16384
or
select name from databasename.dbo.sysusers where udi<16384
replace databasename with real name of you database.
suid is 'server user id ' is reference to sybase login which recorded in master.dbo.syslogins.
16384 is a magic id number from which group names are recorded in sysusers table. (all with id> 16384 are group names not users)
There is also what called 'aliases'. To see all sybase login that are aliased to another login in current database:
select suser_name(suid),suser_nam
Which mean whan anyone named in first column try to access database it will be treated as login from second column.
Next query will give you sybase database user name and corresponding server login (may be different )
select l.name,d.name from master.dbo.syslogins l, databasename.dbo.sysusers d where l.suid=d.suid
Business Accounts
Answer for Membership
by: amitpagarwalPosted on 2003-06-10 at 02:57:15ID: 8689215
i guess you can get all the required information from sysusers table ?