cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Jln_S
Engaged Sweeper II
Hey,

I created an report which shows all Users from an AD group and the assets where there was logged in.
But there are more than one entry because the logged on on some systems. (we don't delete the history)

I would like to show only the newest last seen infomation.

Best regards
Julien

Select Top 1000000 tblADusers.Username,
tblADusers.Userdomain,
tblADusers.Firstname,
tblADusers.Lastname,
tblADusers.Name,
tblADusers.Displayname,
tblADusers.email,
tblADGroups.Name As ADGroupName,
tblADGroups.Description As ADGroupDescription,
tblAssets.Username As Username1,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Userdomain As Userdomain1,
tblAssets.Lastseen
From tblADMembership
Left Join tblADGroups On tblADMembership.ParentAdObjectID =
tblADGroups.ADObjectID
Right Join tblADusers On tblADMembership.ChildAdObjectID =
tblADusers.ADObjectID
Inner Join tblAssets On tblAssets.Username = tblADusers.Username And
tblAssets.Userdomain = tblADusers.Userdomain
Where tblADGroups.Name = 'localITUsers'
Order By tblADusers.Userdomain,
tblADusers.Username,
ADGroupName
0 REPLIES 0