Specific Computer Model per Location
I found a post in the forums that Hightower helped me out with. What I am trying to do is get a report a specific computer model at each defined location. I think with some cleanup this would work.
vComputer.Name AS 'Computer Name',
vHWChassis.[Chassis Package Type],
vHWComputerSystem.[Identifying Number] AS 'Serial Number',
I.Name AS 'Location',
vComputer.[User] AS 'Primary Owner'
FROM vComputer LEFT OUTER
JOIN ResourceAssociation AS loc ON (loc.ChildResourceGuid = vComputer.Guid OR
loc.ParentResourceGuid = vComputer.Guid) AND loc.ResourceAssociationTypeGuid = '05DE450F-39EA-4AAE-8C5F-77817889C27C' LEFT OUTER
JOIN vItem AS I ON loc.ChildResourceGuid = I.Guid LEFT OUTER
JOIN vHWProcessor ON vComputer.Guid = vHWProcessor._ResourceGuid LEFT OUTER
JOIN vHWChassis ON vComputer.Guid = vHWChassis._ResourceGuid LEFT OUTER
JOIN vHWComputerSystem ON vComputer.Guid = vHWComputerSystem._ResourceGuid
(vComputer.IsManaged = 1)
AND (vHWComputerSystem.Model LIKE '%8300%')
ORDER BY 'Computer Name'
This code may still require further clean up, but what I am wondering is does anyone have something like a model / location summary report as well?