Community FAQ
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
laurentiun
Engaged Sweeper III
Hello,

I would like to find users that are not part of some Active Directory group and exclude some users from report.
exemple: users that are not in AD "group1" and exclude administrators.

Thank you.
1 ACCEPTED SOLUTION
Daniel_B
Lansweeper Alumni
You might use a report like the following example:

Select Top 1000000 tblADusers.Username,
tblADusers.Firstname,
tblADusers.Lastname,
tblADusers.Displayname
From tblADusers
Where tblADusers.Username Not Like 'admin%' And tblADusers.ADObjectID Not In
(Select tblADMembership.ChildAdObjectID
From tblADMembership Inner Join tblADGroups On tblADGroups.ADObjectID =
tblADMembership.ParentAdObjectID
Where tblADGroups.Name Like 'group1%')
Order By tblADusers.Username

View solution in original post

1 REPLY 1
Daniel_B
Lansweeper Alumni
You might use a report like the following example:

Select Top 1000000 tblADusers.Username,
tblADusers.Firstname,
tblADusers.Lastname,
tblADusers.Displayname
From tblADusers
Where tblADusers.Username Not Like 'admin%' And tblADusers.ADObjectID Not In
(Select tblADMembership.ChildAdObjectID
From tblADMembership Inner Join tblADGroups On tblADGroups.ADObjectID =
tblADMembership.ParentAdObjectID
Where tblADGroups.Name Like 'group1%')
Order By tblADusers.Username

Reports & Analytics

Ask about reports you're interested in and share reports you've created. Subscribe to receive daily updates of reports shared in the Community.

New to Lansweeper?

Try Lansweeper For Free

Experience Lansweeper with your own data.
Sign up now for a 14-day free trial.

Try Now