Re: sp for User in a Role

From: Narayana Vyas Kondreddi (answer_me@hotmail.com)
Date: 11/25/02


From: "Narayana Vyas Kondreddi" <answer_me@hotmail.com>
Date: Mon, 25 Nov 2002 21:38:39 -0000


Use the functions IS_MEMBER or IS_SRVROLEMEMBER. See Books Online for more
information.

--
HTH,
Vyas, MVP (SQL Server)
SQL Server FAQ, articles, code samples, interview questions and more @
http://vyaskn.tripod.com/
"Bruce L" <bruce@Lovingscents.com> wrote in message
news:e387d0b3.0211251342.572375bf@posting.google.com...
want to create an sp_ that returns true if a user is in a role.
found sp_helprolemember, but dont know how to 'exec sp_' inside another sp
and
see the result set. something like:
create proc up_IsUser
@User varchar(50),
@Role varchar(50)
as
????
if user is in role then return 1
????


Relevant Pages

  • Re: Error with DLL.
    ... You'll have better luck with this problem in a Windows newsgroup :-) ... Vyas, MVP (SQL Server) ... SQL Server FAQ, articles, code samples, interview questions and more @ ...
    (microsoft.public.sqlserver.security)
  • Re: Change a User Name
    ... Vyas, MVP (SQL Server) ... SQL Server FAQ, articles, code samples, interview questions and more @ ...
    (microsoft.public.sqlserver.security)
  • Re: Passwd recovery
    ... Vyas, MVP (SQL Server) ... SQL Server FAQ, articles, code samples, interview questions and more @ ...
    (microsoft.public.sqlserver.security)
  • Re: I have lost the SA password
    ... Vyas, MVP (SQL Server) ... SQL Server FAQ, articles, code samples, interview questions and more @ ...
    (microsoft.public.sqlserver.security)
  • SQL Server and .NET Interview questions free download
    ... You can get full downloads for all real interview questions from ... .NET and SQL Server interview sheet and rate ... JAVA and SQL Server Interview ... XML Integration ...
    (comp.databases.ms-sqlserver)