Nick Strupat
Nick Strupat

Reputation: 5063

How do I give sysadmin right to a user for just one database in a SQL Server instance?

If I run this query, does that give sysadmin rights to the database the query is being run on or to all databases?

exec sp_addsrvrolemember N'username', sysadmin

Upvotes: 2

Views: 10079

Answers (1)

gbn
gbn

Reputation: 432271

sysadmin is SQL Server level admin so it would be all databases with no restrictions at all

You want db_owner in the database for one database

Upvotes: 2

Related Questions