Monday, September 27, 2010

Query to find Machine model & Manufacturer information of a laptop/desktop

select a.Name0,a.User_name0,a.resourceid,a.AD_Site_Name0,comp.Model0,comp.Manufacturer0,ch.Chassistypes0,
CASE ch.Chassistypes0
when '1' then 'DESKTOP'
when '2' then 'DESKTOP'
when '3' then 'DESKTOP'
when '4' then 'DESKTOP'
when '5' then 'DESKTOP'
when '6' then 'DESKTOP'
when '7' then 'DESKTOP'
when '15' then 'DESKTOP'
when '8' then 'LAPTOP'
when '10' then 'LAPTOP'
when '12' then 'LAPTOP'
when '14' then 'LAPTOP'
when '18' then 'LAPTOP'
when '21' then 'LAPTOP'
when '23' then 'SERVER'
when '' then 'UNKNOWN'
END as 'Category',
b.LastScandate as LastSWscan,c.LastHWscan
from v_r_system a left outer join v_GS_LastSoftwareScan b on a.resourceid=b.resourceid
left outer join v_GS_WORKSTATION_STATUS c on a.resourceid=c.resourceid
left outer join v_GS_COMPUTER_SYSTEM comp on a.resourceid=comp.resourceid
left outer join v_GS_SYSTEM_ENCLOSURE ch on ch.ResourceId = a.ResourceId
left outer join v_GS_Operating_SYSTEM os on a.resourceid=os.resourceid
where
a.Client0=1 and a.Obsolete0=0 AND a.Active0=1
Order by ch.chassistypes0

1 Comments:

Blogger Elizabeth J. Neal said...

Thank you for sharing.... Refurbished Laptops in India

October 27, 2014 at 10:39 PM  

Post a Comment

Subscribe to Post Comments [Atom]

Links to this post:

Create a Link

<< Home