Community FAQ
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
matt_steele
Engaged Sweeper II
I have created a simple report which gives me the number of users in a group

Select Top 1000000 Count(tblADGroups.ADGroupID) As Count,
tblADGroups.Name,
Count(tblADusers.Username) As count2,
tblADGroups.Description
From tblADusers
Left Join tblADMembership On tblADMembership.ChildAdObjectID =
tblADusers.ADObjectID
Left Join tblADGroups On tblADMembership.ParentAdObjectID =
tblADGroups.ADObjectID
Group By tblADGroups.Name,
tblADGroups.Description
Order By Count,
tblADGroups.Name

This only gives me the count based on the explicitly in the group.
However I would like to know the number of users in a group including this in sub groups.

If someone could assist.
I see an issue if groups are recursive and am not the the best with SQL.

Regards
0 REPLIES 0

Archive

This board contains archived posts from the retired Lansweeper Forum and Insiders 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