March 2, 2012 at 12:51 pm
Hi DBA's,
I will use Resource Governor in the SQL Server 2008 R2. I want to limit the resource usage from one group of users of my Domain. I have created a login in the SQL Server that is mapped to a group in my AD.
My problem is that I can't find a function that returns me the name of the AD Group which is the same of the login. The function USER, SUSER_SNAME, CURRENT_USER, SESSION_USER, all of them return the Windows account login, not the Windows group, that is the same as the SQL Server login.
Is there any function that returns the AD group?
Thanks in advance,
Lucas Benevides
DBA Cabuloso
________________
DBA Cabuloso
Lucas Benevides
March 2, 2012 at 2:33 pm
Try the IS_MEMBER function.
March 2, 2012 at 2:39 pm
also, these two extended procs examples might help.
one tells you who belongs to a group, the other can tell you all the groups i belong to:
EXEC master..xp_logininfo
@acctname = 'mydomain\lowell',
@option = 'all' -- Show all paths a user gets his auth from
go
EXEC master..xp_logininfo
@acctname = 'mydomain\authenticatedusers',
@option = 'members' -- show group members
Lowell
March 5, 2012 at 6:06 am
Thanks a lot.
The function IS_MEMBER is exactly what I needed.
Best Regards,
Lucas Benevides
DBA Cabuloso
________________
DBA Cabuloso
Lucas Benevides
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply