A N

April 29, 2014

Windows OS WMI filter Queries

Filed under: Tips — donrsh @ 12:22 pm
WINDOWS CLIENT

Windows XP
select * from Win32_OperatingSystem WHERE (Version like “5.1%” or Version like “5.2%”) AND ProductType=”1″
Windows XP (x86)
select * from Win32_OperatingSystem WHERE (Version like “5.1%” or Version like “5.2%”) AND ProductType=”1″ AND NOT OSArchitecture = “x64″
Windows XP (x64)
select * from Win32_OperatingSystem WHERE (Version like “5.1%” or Version like “5.2%”) AND ProductType=”1″ AND OSArchitecture = “x64″

Windows 7
select * from Win32_OperatingSystem WHERE Version like “6.1%” AND ProductType=”1″
Windows 7 (x86)
select * from Win32_OperatingSystem WHERE Version like “6.1%” AND ProductType=”1″ AND NOT OSArchitecture = “x64″
Windows 7 (x64)
select * from Win32_OperatingSystem WHERE Version like “6.1%” AND ProductType=”1″ AND OSArchitecture = “x64″

Windows 8
select * from Win32_OperatingSystem WHERE Version like “6.2%” AND ProductType=”1″
Windows 8 (x86)
select * from Win32_OperatingSystem WHERE Version like “6.2%” AND ProductType=”1″ AND NOT OSArchitecture = “x64″
Windows 8 (x64)
select * from Win32_OperatingSystem WHERE Version like “6.2%” AND ProductType=”1″ AND OSArchitecture = “x64″

Windows 8.1
select * from Win32_OperatingSystem WHERE Version like “6.3%” AND ProductType=”1″
Windows 8.1 (x86)
select * from Win32_OperatingSystem WHERE Version like “6.3%” AND ProductType=”1″ AND NOT OSArchitecture = “x64″
Windows 8.1 (x64)
select * from Win32_OperatingSystem WHERE Version like “6.3%” AND ProductType=”1″ AND OSArchitecture = “x64″

WINDOWS SERVER

Windows Server 2003 (DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”2″
Windows Server 2003 (non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”3″
Windows Server 2003 (x86, DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”2″ AND NOT OSArchitecture = “x64″
Windows Server 2003 (x86, non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”3″ AND NOT OSArchitecture = “x64″
Windows Server 2003 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”2″ AND OSArchitecture = “x64″
Windows Server 2003 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2%” AND ProductType=”3″ AND OSArchitecture = “x64″

Windows Server 2003 R2 (DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”2″
Windows Server 2003 R2 (non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”3″
Windows Server 2003 R2 (x86, DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”2″ AND NOT OSArchitecture = “x64″
Windows Server 2003 R2 (x86, non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”3″ AND NOT OSArchitecture = “x64″
Windows Server 2003 R2 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”2″ AND OSArchitecture = “x64″
Windows Server 2003 R2 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “5.2.3%” AND ProductType=”3″ AND OSArchitecture = “x64″

Windows Server 2008 (DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”2″
Windows Server 2008 (non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”3″
Windows Server 2008 (x86, DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”2″ AND NOT OSArchitecture = “x64″
Windows Server 2008 (x86, non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”3″ AND NOT OSArchitecture = “x64″
Windows Server 2008 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”2″ AND OSArchitecture = “x64″
Windows Server 2008 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.0%” AND ProductType=”3″ AND OSArchitecture = “x64″

Windows Server 2008 R2 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “6.1%” AND ProductType=”2″
Windows Server 2008 R2 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.1%” AND ProductType=”3″

Windows Server 2012 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “6.2%” AND ProductType=”2″
Windows Server 2012 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.2%” AND ProductType=”3″

Windows Server 2012 R2 (x64, DC)
select * from Win32_OperatingSystem WHERE Version like “6.3%” AND ProductType=”2″
Windows Server 2012 R2 (x64, non-DC)
select * from Win32_OperatingSystem WHERE Version like “6.3%” AND ProductType=”3″
Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: