SCCM WQL Query: Machines Without Endpoint Protection Installed

If you need to find machines that have the SCCM client installed but are somehow missing the Endpoint Protection client: a common gap check after enabling Endpoint Protection policies: this WQL query builds a collection based on what’s actually listed in each machine’s installed programs. The Query (Updated for Current Configuration Manager) select SMS_R_SYSTEM.ResourceID, SMS_R_SYSTEM.ResourceType, […]

SCCM Wql Query For Machines Without Endpoint Protection Installed
If you need to find machines that have the SCCM client installed but are somehow missing the Endpoint Protection client: a common gap check after enabling Endpoint Protection policies: this WQL query builds a collection based on what’s actually listed in each machine’s installed programs.

The Query (Updated for Current Configuration Manager)

select
SMS_R_SYSTEM.ResourceID, SMS_R_SYSTEM.ResourceType, SMS_R_SYSTEM.Name,
SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup, SMS_R_SYSTEM.Client
from SMS_R_System
inner join SMS_G_System_EndpointProtectionStatus on SMS_G_System_EndpointProtectionStatus.ResourceID = SMS_R_System.ResourceId
where SMS_G_System_EndpointProtectionStatus.NotYetInstalled = 1
and SMS_R_System.Client = 1
This version drops the old Add/Remove Programs based subquery entirely and instead uses the built-in SMS_G_System_EndpointProtectionStatus class, the same data source behind Monitoring > Endpoint Protection Status in the console. Its NotYetInstalled flag is set when the Endpoint Protection client has not yet been installed on a machine, so there is no product-name string to keep in sync with your ConfigMgr version.

A Note on the Product Name for Current Configuration Manager

The original version of this query (System Center 2012 Endpoint Protection in an Add/Remove Programs subquery) reflected the branding used in the 2012-era ConfigMgr releases this site originally covered. That approach was fragile on current branch, since the product name string could vary and modern Configuration Manager manages Defender directly through policy rather than installing a distinct, separately-listed legacy client. The query above replaces that approach with the SMS_G_System_EndpointProtectionStatus class instead, which reflects real-time protection state rather than an installed-programs snapshot.

Troubleshooting False Positives

Because this query depends entirely on hardware inventory data being current, a machine that genuinely has Endpoint Protection installed can still show up in the collection if its last inventory cycle ran before the client was deployed, or if hardware inventory itself is disabled or throttled on that client. Before treating a result as a real gap, check the Last Hardware Scan date on the resource: a stale scan date is the most common cause of false positives with this type of query, not a genuinely missing client.

Resources


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.

9 thoughts on “SCCM WQL Query: Machines Without Endpoint Protection Installed

  1. I want to look for a particular version which is not installed . like check collections for workstations with system center endpoint protection where version is not 4.10.209.0

  2. I want to look for a particular version which is not installed . like check collections for workstations with system center endpoint protection where version is not 4.10.209.0

  3. I want to look for a particular version which is not installed . like check collections for workstations with system center endpoint protection where version is not 4.10.209.0

  4. Pretty sure your query shouldn’t have breaks all in it 🙂

    1. Thanks for letting us know – some of our formatting on the older posts went a bit crazy when we migrated to WordPress from Blogger. Updated now…

  5. Pretty sure your query shouldn’t have breaks all in it 🙂

    1. Thanks for letting us know – some of our formatting on the older posts went a bit crazy when we migrated to WordPress from Blogger. Updated now…

  6. Pretty sure your query shouldn’t have breaks all in it 🙂

    1. Thanks for letting us know – some of our formatting on the older posts went a bit crazy when we migrated to WordPress from Blogger. Updated now…

Comments are closed.