Jump to content
EduGeek EdSec 2026 is Go! 27th Oct in Derby! Join us for a day of EdTech security focused talks, networking, and an evening social ×

Recommended Posts

Posted
You could use a NOT and list the Windows 10 build versions you have in place. Therefore, any version that is NOT one of those, will detect as 11. That'd be fairly neat.
Posted

You could try adding a second filter using “caption” to the query

 

We use these within SCCM for similar purposes between editions etc

 

Steve

Posted

It generally works slightly slower than just version numbers, but it's things like: SELECT Caption FROM Win32_OperatingSystem WHERE Caption LIKE "Microsoft Windows 11%"

 

You could also add in version numbers if you want Win11 21H2 only etc but depends if you just want Win11 any version (We break it down a lot more in SCCM to Win10 1909, Win10 20H2 etc)

 

Using cmd/powershell, run "wmic os get caption" and it'll return what you need to use in the caption for a said machine

 

Steve

  • Thanks 1
Posted

I'm using

 

select * from Win32_OperatingSystem where Version like "10.0.2%"

 

This seems to work for Windows 11 only. I have changed my Windows 10 to 10.0.1% and made one for 10 and above which uses 10.0%

  • 1 year later...
Posted

Just starting to look at W11.

 

Need to change one of my existing Windows 10 filters which is picking up everything after W10 1607.

 

This filter is:

 

SELECT * FROM Win32_OperatingSystem WHERE BuildNumber >= "15063" AND ProductType = "1"

 

 

Everything on my domain is now either 20H2 or 22H2 so I was going to create a new filter to replace the one above where applicable.

 

select Version,ProductType from Win32_OperatingSystem where (Version="10.0.19042" or Version="10.0.19045") and ProductType=1

 

 

Then add a new filter for Windows 11

 

select Version,ProductType from Win32_OperatingSystem where Version LIKE "10.0.22000%" and ProductType = "1"

 

 

Can anyone see any issues with the above?

Posted
Just starting to look at W11.

 

Need to change one of my existing Windows 10 filters which is picking up everything after W10 1607.

 

This filter is:

 

SELECT * FROM Win32_OperatingSystem WHERE BuildNumber >= "15063" AND ProductType = "1"

 

 

Everything on my domain is now either 20H2 or 22H2 so I was going to create a new filter to replace the one above where applicable.

 

select Version,ProductType from Win32_OperatingSystem where (Version="10.0.19042" or Version="10.0.19045") and ProductType=1

 

 

Then add a new filter for Windows 11

 

select Version,ProductType from Win32_OperatingSystem where Version LIKE "10.0.22000%" and ProductType = "1"

 

 

Can anyone see any issues with the above?

 

Found this tool really useful.

 

https://sdmsoftware.com/389932-gpo-freeware-downloads/wmi-filter-validation-utility/

  • 2 weeks later...
Posted

I use this, if you pick 10.22000% you only match Win 11 RTM, and not 22H2 etc.

 

select Version,ProductType from Win32_OperatingSystem where Version LIKE "10.0.2%" and ProductType = "1"

  • Thanks 2

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...