SCCM Collection by IP Range

How to build a sccm collection of computers based on IP Range?

Here is the sccm query you can use:

—  just first create a collection, and choose ” query rule ” in “Membership Rules”.

— change the IP range below to the IP range you want to use.

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 where SMS_R_System.IPSubnets in (“”, “”)