Cannot alter the role 'db_owner', because it does not exist or you do not have permission.
This post describes how to fix the error "Cannot alter the role 'db_owner', because it does not exist or you do not have permission". This also applies to the role 'db_datareader'.
Cause
This can occur if your server collation is case sensitive and you're trying to alter a role in SQL using the sp_addrolemember stored procedure e.g.EXEC sp_addrolemember 'db_Owner', 'dbo';
To check your server collation:
To check your database collation:
SELECT DATABASEPROPERTYEX('%DATABASENAME%', 'Collation') SQLCollation;
Note: You can get a description of each COLLATION using this query:
SELECT * FROM fn_helpcollations();
Solution
EXEC sp_addrolemember 'db_owner', 'dbo';
Video
Watch the video: Cannot alter the role, because it does not exist or you do not have permissionRelated Posts
- Database is not configured for database mirroring. (Microsoft SQL Server, Error: 1416)
- The client and server cannot communicate, because they do not possess a common algorithm
Comments
Post a Comment