‎07-31-2013 07:48 PM
Solved! Go to Solution.
‎08-01-2013 06:25 PM
Select Top 1000000 tblAssetGroups.AssetGroup As Site,
tblSoftwareUni.softwareName As Software,
tblSoftwareUni.SoftwarePublisher As Publisher,
Case tblSoftwareUni.Approved When 0 Then 'unrated' When 1 Then 'authorized'
When 2 Then 'unauthorized' End As [Authorization],
Count(tblSoftware.AssetID) As Total
From tblSoftware
Inner Join tblAssets On tblSoftware.AssetID = tblAssets.AssetID
Inner Join tblSoftwareUni On tblSoftware.softID = tblSoftwareUni.SoftID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tblAssetGroupLink On tblAssets.AssetID = tblAssetGroupLink.AssetID
Inner Join tblAssetGroups On tblAssetGroups.AssetGroupID =
tblAssetGroupLink.AssetGroupID
Where tblAssetCustom.State = 1
Group By tblAssetGroups.AssetGroup,
tblSoftwareUni.softwareName,
tblSoftwareUni.SoftwarePublisher,
Case tblSoftwareUni.Approved When 0 Then 'unrated' When 1 Then 'authorized'
When 2 Then 'unauthorized' End
Order By Site,
Total Desc
3 weeks ago
I realize this is a really old thread, but I haven't found anywhere that this item has been addressed since.
I have had success adding the following in place of the CASE statement proffered by @Hemoco:
Case tblSoftwareUni.Approved
When 0 Then 'dot_grey.png'
When 1 Then 'tick.png'
When 2 Then 'red_cross.png'
End As icon,
The icon files themselves are all located in the website images directory (e.g. c:\Program Files (x86)\Lansweeper\Website\images). I chose to use the tick and cross icons, but you could just use the 'dot' icons (i.e. dot_grey.png, dot_green.png, dot_red.png).
The field name has to be icon; I haven't found any other combination that works. The icon will always show up to the left of all the other fields, no matter where you actually place it in your query.
Hopefully someone finds this useful.
‎03-10-2015 11:53 AM
‎08-01-2013 07:31 PM
‎08-01-2013 07:14 PM
‎08-01-2013 07:10 PM
‎08-01-2013 07:08 PM
‎08-01-2013 06:55 PM
‎08-01-2013 06:25 PM
Select Top 1000000 tblAssetGroups.AssetGroup As Site,
tblSoftwareUni.softwareName As Software,
tblSoftwareUni.SoftwarePublisher As Publisher,
Case tblSoftwareUni.Approved When 0 Then 'unrated' When 1 Then 'authorized'
When 2 Then 'unauthorized' End As [Authorization],
Count(tblSoftware.AssetID) As Total
From tblSoftware
Inner Join tblAssets On tblSoftware.AssetID = tblAssets.AssetID
Inner Join tblSoftwareUni On tblSoftware.softID = tblSoftwareUni.SoftID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tblAssetGroupLink On tblAssets.AssetID = tblAssetGroupLink.AssetID
Inner Join tblAssetGroups On tblAssetGroups.AssetGroupID =
tblAssetGroupLink.AssetGroupID
Where tblAssetCustom.State = 1
Group By tblAssetGroups.AssetGroup,
tblSoftwareUni.softwareName,
tblSoftwareUni.SoftwarePublisher,
Case tblSoftwareUni.Approved When 0 Then 'unrated' When 1 Then 'authorized'
When 2 Then 'unauthorized' End
Order By Site,
Total Desc
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now