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

I am attempting to run a report pulling selected computers by running the below query.  However, it is not including some of the computers that are in the query. I can search for the computer, that does not show up in the query, successfully. Is this to be expected? What am I missing here as to why some are not showing reports?

Select Top 1000000 tblassets.AssetID,
tblassets.AssetName,
tsysassettypes.AssetTypename,
tsysassettypes.AssetTypeIcon10 As icon,
tblassets.IPAddress,
tblassets.Lastseen,
tblassets.Lasttried,
tblassets.Username,
tblADusers.Displayname,
tblADusers.email,
tblassets.BuildNumber,
tblassets.Version
From tblassets
Inner Join tblassetcustom On tblassets.AssetID = tblassetcustom.AssetID
Inner Join tsysassettypes On tsysassettypes.AssetType = tblassets.Assettype
Inner Join tblADusers On tblADusers.Username = tblassets.Username
Where (tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = '' Or
tblassets.AssetName = ''
)

4 REPLIES 4
Mister_Nobody
Honored Sweeper II

Change "inner" to "left"

Same issue.

It looks like for tblADUsers, you have to join both the Username and Userdomain fields to tblAssets.

Inner Join tblADusers On tblADusers.Userdomain = tblassets.userdomain

The only other thing I can think of is removing the tblassetcustom join as it doesn't look like it's used anywhere. 

zinger3031
Engaged Sweeper II

Any help here? Or do I need to open a support ticket?