Combining multiple queries in one collection – SCCM

I was hired for one secondment, and I moved to  much bigger  environment. And one of task was to deploy Office 2016. Ill write another post of deploying Office 2016 with scripts to uninstall previous version of Office.

After some digging, I figured that environment has mixed versions of Office in place.  After creating initial Collections for Office 2010 and 2013, also I created the 32bit versions of collection.
Below you can find examples for query of Office 2016

The best way to detect applications is to use GUID of programs you wish to detect.

Also you can use this information  using powershell command to get some third party application GUID and implement detection method.

The command is:

wmic product where "Name like '%Office%'" get name,version,identifyingnumber

 

This is GUID for Office versions.

Office 2013 (32-bit) 

Display Name                                  Product ID
------------                                  ----------
Microsoft Office Professional Plus 2013       {90150000-0011-0000-0000-0000000FF1CE}
Microsoft Visio Professional 2013             {90150000-0051-0000-0000-0000000FF1CE}
Microsoft Project Professional 2013           {90150000-003B-0000-0000-0000000FF1CE}

Office 2013 (64-bit) 

Display Name                                  Product ID
------------                                  ----------
Microsoft Office Professional Plus 2013       {90150000-0011-0000-1000-0000000FF1CE}
Microsoft Visio Professional 2013             {90150000-0051-0000-1000-0000000FF1CE}
Microsoft Project Professional 2013           {90150000-003B-0000-1000-0000000FF1CE}

Office 2016 (64-bit) 

Display Name                                  Product ID
------------                                  ----------
Microsoft Office Professional Plus 2016       {90160000-0011-0000-1000-0000000FF1CE}
Microsoft Visio Professional 2016             {90160000-0051-0000-1000-0000000FF1CE}
Microsoft Project Professional 2016           {90160000-003B-0000-1000-0000000FF1CE}

 

This is example of collection query based on version of Office installed. Its pretty self explanatory.

 

Office 2013 – 32 bit Detection rule
office 2016
Office 2016 – 64 bit Detection  rule

 

 

 

 

 

 

 

 

But I wanted to check if there is computers that have Office 2010 and 2016, installed, or any other combination.

Continue reading “Combining multiple queries in one collection – SCCM”