‎09-17-2013 02:58 PM
‎09-26-2013 05:07 PM
‎09-27-2013 05:45 PM
tagenalum wrote:
I tried both queries, but the first one (Users and the last PC they logged on) gives no results.
Are you sure it is correct? I did a copy / paste into the report editor.
Thanks.
Select Top 1000000 SubQuery.Username,
SubQuery.Domain As Userdomain,
SubQuery.LastLogon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain
From tblCPlogoninfo
Inner Join (Select Top 1000000 tblCPlogoninfo.Username,
tblCPlogoninfo.Domain,
Max(tblCPlogoninfo.logontime) As LastLogon
From tblCPlogoninfo
Group By tblCPlogoninfo.Username,
tblCPlogoninfo.Domain) SubQuery On tblCPlogoninfo.Username =
SubQuery.Username And tblCPlogoninfo.Domain = SubQuery.Domain And
tblCPlogoninfo.logontime = SubQuery.LastLogon
Inner Join tblAssets On tblAssets.AssetID = tblCPlogoninfo.AssetID
‎09-17-2013 05:47 PM
‎09-17-2013 05:39 PM
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now