SCCM – Query Powershell Version

querysccm

I am trying to create create a query in SCCM to show how many computers are installed with the different Powershell-versions. I suspect we have a mix of v2,v3 and v4, but I need to know how many and their computer names. Does anyone know how I can accomplish this? I couldnt find anything about this online.

I would prefer a query because I dont want to make a report (I am not comfertable with the report builder in SCCM 2012).

Best Answer

You can do this if you enable the Software Inventory function in your client settings. By default SINV disables scanning of C:\Windows so you need to re-enable the Powershell path %windir%\System32\WindowsPowerShell\v1.0
After that, you can create Queries or Collections that leverage the "Softare Files" attribute class to see what you have. So far I've mapped out the following values & version numbers.

v1,2 Less Than 6.2
v3   Like      6.2.%
v4   Like      6.3.%

Clientsettings ClientSettings2 QueryCriteria