cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
ogeccut
Engaged Sweeper II
I am trying to create a report to generate Computer names and last logged in user.
My final goal would be to match last user to AD property "MangedBy", but I don't if that's possible. If it is the I would like to flat it if there is a difference.
Can lansweeper read AD properties?
Thank you.
1 ACCEPTED SOLUTION
Susan_A
Lansweeper Alumni
Lansweeper scans a number of Active Directory user and computer attributes and properties. These are stored in the "tblAD..." database tables. I've included a sample report below that lists your Windows computers, their last logged on user and the manager of that user. You can add this report to your Lansweeper installation by following these instructions.
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblAssets.Lasttried,
tblAssets.Username,
tblAssets.Userdomain,
tblADusers.Firstname,
tblADusers.Lastname,
tblADusers.Name,
tblADusers.Displayname,
tblADusers.email,
tblADObjects.sAMAccountName As ManagerName,
tblADObjects.domain As ManagerDomain,
tsysAssetTypes.AssetTypeIcon10 As icon
From tblADObjects
Right Join tblADusers On tblADObjects.ADObjectID =
tblADusers.ManagerADObjectId
Right Join tblAssets On tblADusers.Username = tblAssets.Username And
tblADusers.Userdomain = tblAssets.Userdomain
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Where tblAssetCustom.State = 1 And tsysAssetTypes.AssetType = -1
Order By tblAssets.Domain,
tblAssets.AssetName

View solution in original post

1 REPLY 1
Susan_A
Lansweeper Alumni
Lansweeper scans a number of Active Directory user and computer attributes and properties. These are stored in the "tblAD..." database tables. I've included a sample report below that lists your Windows computers, their last logged on user and the manager of that user. You can add this report to your Lansweeper installation by following these instructions.
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblAssets.Lasttried,
tblAssets.Username,
tblAssets.Userdomain,
tblADusers.Firstname,
tblADusers.Lastname,
tblADusers.Name,
tblADusers.Displayname,
tblADusers.email,
tblADObjects.sAMAccountName As ManagerName,
tblADObjects.domain As ManagerDomain,
tsysAssetTypes.AssetTypeIcon10 As icon
From tblADObjects
Right Join tblADusers On tblADObjects.ADObjectID =
tblADusers.ManagerADObjectId
Right Join tblAssets On tblADusers.Username = tblAssets.Username And
tblADusers.Userdomain = tblAssets.Userdomain
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Where tblAssetCustom.State = 1 And tsysAssetTypes.AssetType = -1
Order By tblAssets.Domain,
tblAssets.AssetName