Link to home
Start Free TrialLog in
Avatar of anushahanna
anushahannaFlag for United States of America

asked on

permissions of SQLServerMSSQLUser$ComputerName$MSSQLSERVER

is there a tSQL code you could check what are the permissions bestowed to the above group.

Avatar of Vitor Montalvão
Vitor Montalvão
Flag of Switzerland image

What's that?
An AD group or AD user?
Wich SQL Server version are you using?
Avatar of anushahanna


user group created by installation?
Now I see. Isn't really a user name but a variable :)
You have in that article what kind of permissions is needed in AD.

But those are only Default permissions, right? it might have changed over the years, and how do you check where its levels are now?

Why do you say it is a variable? Even it is a variable, it works with xp_logininfo, which is supposed to return information about Windows users and Windows groups.
As far I know about Microsoft articles they are always up to date.
Variable it's the computer name.  :)

Anyway, that user is really a group that is created locally in the server and not in AD.
Thanks VMontalvao. My variable is COMNTR333.

I confirmed the following is in syslogins.

then i created an user in tblTracker databases
use tblTracker
create user [COMNTR333\SQLServer2005MSSQLUser$COMNTR333$MSSQLSERVER] for login [COMNTR333\SQLServer2005MSSQLUser$COMNTR333$MSSQLSERVER]

then i tried to see its current permissions

USE tblTracker  
SELECT * FROM fn_my_permissions(NULL, NULL)

but it gives error:
Cannot execute as the database principal because the principal "COMNTR333\SQLServer2005MSSQLUser$COMNTR333$MSSQLSERVER" does not exist, this type of principal cannot be impersonated, or you do not have permission.

if we cannot impersonate, is there any options to check its permissions?

Avatar of Vitor Montalvão
Vitor Montalvão
Flag of Switzerland image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks VMontalvao.