SCCM Collection Query for Devices with specific software installed and version or below

If you need to identify machines with specific software installed on a device but would also like to know whether they have a certain version of the stated software or below, then you can use the below query. This can help with software upgrades to identify machines that have not yet been upgraded. SCCM Collection […]

SCCM Collection Query For Devices With Specific Software Installed

If you need to identify machines with specific software installed on a device but would also like to know whether they have a certain version of the stated software or below, then you can use the below query.

This can help with software upgrades to identify machines that have not yet been upgraded.

SCCM Collection Query

select distinct
SMS_R_System.Name,
SMS_R_System.ClientVersion
from SMS_R_System
inner join SMS_G_System_ADD_REMOVE_PROGRAMS
on SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID = SMS_R_System.ResourceId
where SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName = "Shoretel Communicator"
and SMS_G_System_ADD_REMOVE_PROGRAMS.Version <= "17.60.9211.0"
order by SMS_R_System.Name, SMS_R_System.ClientVersion

You can change the where statements for the software you want to query and also the version number. In the example above, we are using the following:

  • Software = Shoretel Communicator
  • Version is equal to or lower than – 17.60.9211.0

Which actually translates as – return to me any machines that have Shoretel Communicator v12.3 (17.60.9211.0) or below installed on them.

You can also change the = for LIKE in the query if you want to use the % wildcard for the DisplayName value.

You can also change the <= for >= if you want higher than version.

How do I create the SSRS report?

We have now created a guide that will help you to create your SSRS reports based on the data that this guide will pull into the Configuration Manager database.

You can access this guide by clicking the link below:

Create an SSRS Report using Configuration Manager Database Data

Comments

If you have any problems with any of the above, then please leave your comments and questions below using our comments system and we will try to get back to you as soon as we can.

We also like to hear back any success stories too, so if you have used our guide and found it helpful, we would love to hear from you.

🛠️

Gear We Recommend

Testing configs is easier with a dedicated admin machine set up right. Here’s the kit we use.

Browse our Windows Admin Toolkit picks on Amazon

As an Amazon Associate, TechyGeeksHome earns from qualifying purchases.


Discover more from TechyGeeksHome

Subscribe to get the latest posts sent to your email.

Andrew Armstrong

Andrew Armstrong is a UK-based IT professional with 26+ years of hands-on experience in Windows, Windows Server, SCCM/ConfigMgr, Active Directory, PowerShell, and enterprise infrastructure.

He founded TechyGeeksHome in 2010 and has published over 1,500 practical guides covering real-world IT problems and solutions. When not solving IT problems,

Andrew develops free Windows utilities including Ultimate Settings Panel, which has been downloaded over 850,000 times.

4 thoughts on “SCCM Collection Query for Devices with specific software installed and version or below

Comments are closed.