skissinger
Posts: 2293
Score: 145 Joined: 9/13/2001 From: Sherry Kissinger Status: offline
|
*warning* work in progress! Pre-requisite: in sms_def.mof, change FALSE to TRUE for the SMS_Report "Battery", and in the keys below, you only need TRUE for 2 things: for DeviceID (the key field) and Name Here's what I've got so far as a report. However, there is still some debate going on about whether or not the criteria of Battery Model is really all you need to look for. If a consensus is reached, I'll update this thread. select distinct SYS.Netbios_Name0, sys.User_Name0 [Last Logged on User], sys.AD_Site_Name0, Batt.Name0 [Battery Model], case CSYS.Model0 When '23718VU' then 'IBM X40 23718VU' When '2371K4U' then 'IBM X40 2371K4U' When '2373k1u' then 'IBM T42P Centrino 2373K1U' when '2373k9u' then 'IBM T42P #1 2373K9U' When '23736zu' then 'IBM T42 23736ZU' When '237375u' then 'IBM T40 237375U' When '2373w1j' then 'IBM T40 2373W1J' When '2373pu7' then 'IBM T40 2373PU7' When '237372u' then 'IBM T40 237372U' when '23718vu' then 'IBM X40 23718VU' when '200755u' then 'IBM T60 15" ' when '200768u' then 'IBM T60 14" ' when '170685u' then 'IBM X60 (170685u)' when '170686u' then 'IBM X60 (170686u)' else CSYS.Model0 end as 'Model' from v_r_system sys inner join v_GS_Battery batt on batt.resourceid=sys.resourceid JOIN v_GS_Workstation_Status ws on batt.ResourceID=ws.ResourceID join v_GS_Computer_System CSYS on SYS.ResourceID=CSYS.ResourceID where (batt.name0 like '%92P1072%' or batt.name0 like '%92P1088%' or batt.name0 like '%92p1142%' or batt.name0 like '%92p1170%' or batt.name0 like '%92p1174%' or batt.name0 like '%92p1073%' or batt.name0 like '%92p1089%' or batt.name0 like '%92p1141%' or batt.name0 like '%92p1169%' or batt.name0 like '%92p1173%' or batt.name0 like '%93p5028%' or batt.name0 like '%93p5030%') and datediff(day,ws.LastHWScan,getdate()) < "30" order by sys.ad_site_name0
|