Solved

users who have DML privileges in SQL 2000

Posted on 2010-08-20
4
376 Views
Last Modified: 2012-05-10
How can you script out the users who have DML privileges in SQL 2000?

thanks
0
Comment
Question by:anushahanna
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 60

Accepted Solution

by:
Kevin Cross earned 500 total points
ID: 33491825
anushahanna:Let's test my memory...give these a try:-- this table will map for you userid (uid) to sid to username|rolename-- using the is??? flags you can figure out if user, role, etc. select *from sys.sysusers;-- matches user to things like sysadmin, serveradmin, etc.-- uses sid, so will need to match to sysusers using sidselect *from sys.syslogins;-- has explicitly assigned rights-- has a grantor and grantee field that matches to sysusers uid-- e.g., grantee_principal_id = uidselect * from sys.database_permissions;With the combination, you can try to find out what you are looking for via T-SQL.Regards,Kevin
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33500717
Thanks Kevin;

I am able to get the first 2 in SQL 2000 with
select * from dbo.sysusers
select * from master.dbo.syslogins

what would be the equivalent of sys.database_permissions?
0
 
LVL 60

Assisted Solution

by:Kevin Cross
Kevin Cross earned 500 total points
ID: 33502808
http://msdn.microsoft.com/en-us/library/aa260604(SQL.80).aspx
try syspermissions or see if the data is in syslogins ... has been too long since I actually looked at a SQL 2000 server instance. Have database in SQL 2000 compatibility mode where the above works as typed, but that is due to the underlying engine being SQL 2008 most likely.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33503375
Thanks for the direction, Kevin.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question