Thursday, July 2, 2015

The WMI Cookbook

WMI Filters to Select Computers to which to apply group policy:

Target Win 7 32 bit machines:
select * from Win32_OperatingSystem WHERE Version like "6.1%" AND ProductType="1" AND NOT OSArchitecture = "64-bit"

Target Win 7 64Bit machines:
select * from Win32_OperatingSystem WHERE Version like "6.1%" AND ProductType="1" AND OSArchitecture = "64-bit"

Target any 32 bit OS;
SELECT AddressWidth FROM Win32_Processor WHERE AddressWidth ='32'

Target any 64Bit OS:
SELECT AddressWidth FROM Win32_Processor WHERE AddressWidth ='64'

No comments:

Post a Comment