Finding roles granted to users and group ( 2 )

  •  

    Hi All

    I want to retrieve the list of all the roles that a user has, including the ones he got from is windows group.

     

                               Type           Role Connect    Role DoImportantThing

    myDomain\VIP        Win Group    Granted           Granted

    myDomain\NotVIP   Win Group    Granted            Not Granted

    myDomain\A          Win             Not Granted      Not Granted

    myDomain\B          Win             Not Granted      Not Granted

    myDomain\C          Win             Granted           Not Granted

    note that myDomain\A is part of windows group myDomain\VIP in the domain and myDomain\B is part of myDomain\NotVip.

     

    I would expect the following list to be constructed.

    myDomain\A : connect, DoImportatnThings

    myDomain\B : connect

    myDomain\C : connect

    Thanks for your inputs.

    Sylvain

  • Extended procedure xp_logininfo can supply the members of a Windows Group. For Windows Groups within Windows Groups, you will need to write some recursive SQL (while loop) to get the members.

    Alternatively, there is an OLE DB Provider for Microsoft Directory Services.

    SQL = Scarcely Qualifies as a Language

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply