-- Author: Number2 (John Nelson) - http://number2blog.com -- Disclaimer: This code is offered as-is and is not provided for any particular purpose -- I can't guarantee that it works, nor can I guarantee it won't break something. -- However, it is to the best of my understanding, pretty good code. -- Modify it to meet your needs and TEST TEST TEST! -- -- Description: This query can go right into an SMS collection query. It is intended to -- show machines that are missing latest WMI stability updates 933061, 933062 SELECT sys.ResourceID, sys.ResourceType, sys.Name, sys.SMSUniqueIdentifier, sys.ResourceDomainORWorkgroup, sys.Client FROM SMS_R_System AS sys INNER JOIN SMS_G_System_SoftwareFile AS sf ON sys.ResourceID = sf.ResourceID WHERE sf.FileName = "REPDRVFS.DLL" AND sf.resourceID NOT IN (SELECT resourceID FROM SMS_G_System_SoftwareFile AS sf2 WHERE sf2.FileName = "REPDRVFS.DLL" AND (sf2.FileVersion LIKE "5.2.3790.2936%" OR sf2.FileVersion LIKE "5.2.3790.40[8-9][0-9]%" OR sf2.FileVersion LIKE "5.2.3790.4[1-9][0-9][0-9]%" OR sf2.FileVersion LIKE "5.2.3790.[5-9][0-9][0-9][0-9]%" OR sf2.FileVersion LIKE "5.1.2600.313[8-9]%" OR sf2.FileVersion LIKE "5.1.2600.31[4-9][0-9]%" OR sf2.FileVersion LIKE "5.1.2600.3[2-9][0-9][0-9]%" OR sf2.FileVersion LIKE "5.1.2600.[4-9][0-9][0-9][0-9]%" OR sf2.FileVersion LIKE "[6-9]%")) AND sys.decommissioned = 0 AND sys.obsolete = 0 AND sys.client = 1