‎02-20-2020 10:30 PM
< 'Black: 1'will then display when Black is lower than 1. So, cool!
‎06-12-2020 10:12 PM
Select Top 1000000
tblState.Statename,
tblAssets.AssetID,
tblAssets.AssetName,
tsysAssetTypes.AssetTypeIcon10 As icon,
'http://' + tblAssets.IPAddress As [hyperlink_IP Address],
tblAssets.IPNumeric As [IP (sortable)],
tblAssets.IPAddress As [hyperlink_name_IP Address],
tblAssets.Mac As [MAC Address],
tblAssets.Lastseen,
tblAssetCustom.Location,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Serialnumber,
tblAssetCustom.Printedpages,
tblAssetCustom.PrintedColorPages,
tblAssetCustom.PrintedMonoPages,
tblAssetCustom.Printerstatus,
tblCustDevPrinter.TonerNr,
tblCustDevPrinter.TonerName,
tblCustDevPrinter.TonerColorName,
tblCustDevPrinter.TonerColorNr,
tblCustDevPrinter.TonerMaximum,
tblCustDevPrinter.TonerRemaining,
Convert(VarChar(10), Cast( CASE
WHEN tblCustDevPrinter.TonerMaximum > 0 AND tblCustDevPrinter.TonerRemaining >= 0
THEN tblCustDevPrinter.TonerRemaining / tblCustDevPrinter.TonerMaximum * 100
END AS Decimal(6,2)) ) + '%' AS [Toner %],
tblCustDevPrinter.LastChanged
From
tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Join tblState On tblState.State = tblAssetCustom.State
LEFT JOIN tblCustDevPrinter ON tblCustDevPrinter.AssetID = tblAssets.AssetID
Where
tsysAssetTypes.AssetTypename = 'Printer'
AND tblCustDevPrinter.TonerName NOT LIKE '%Maintenance%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Drum%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Fuser%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Transfer%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Waste%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Collection%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Clean%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Roller%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Fan Filter%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Kit%'
AND tblCustDevPrinter.TonerName NOT LIKE '%Belt%'
Order By
tblAssetCustom.Manufacturer,
tblAssets.AssetName,
tblCustDevPrinter.TonerNr
‎06-11-2020 08:00 PM
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now