Share via

SCCM Collections and Memberships

Ronald Seow 206 Reputation points
2021-04-19T03:03:08.857+00:00

Good morning!

Has anyone experience a collection contains another collection in its membership but that collection is not in the list of collections in within SCCM? The version of SCCM I have is 1702.

Example;
in Collection_A the members are Host_1, Host_2, Collection_B, Collection_C.
in Collections, Collection_B could not be located and also not listed when querying the table v_Collections or v_CollectionMemberClientBaselineStatus

Also, does anyone have a SQL query to query for members in a collection including nested collections that can share with me?

Appreciate any advise.

Thank you and best regards.
Ronald

Microsoft Security | Intune | Configuration Manager | Other
0 comments No comments

Answer accepted by question author

  1. Jason Sandys 31,421 Reputation points Microsoft Employee Moderator
    2021-04-19T14:18:42.867+00:00

    Plus 1 to @AllenLiu-MSFT 's comments: your site is way out of support.

    What's most likely happening here is that there was a design flaw where renamed collections did not get updated in include and exclude rule names; i.e., if you renamed a collection that was referenced in an include or exclude rule, the rule would still work, but the display name for that rule wouldn't be updated to reflect the new name.

    The fix here is to upgrade to a supported version of ConfigMgr as this was addressed at some point in the last 4 years.

    Was this answer helpful?

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. AllenLiu-MSFT 49,441 Reputation points Microsoft External Staff
    2021-04-19T08:30:46.427+00:00

    Hi, @Ronald Seow
    Thank you for posting in Microsoft Q&A forum.
    We can use below SQL query to find all memberships in a collection, replace the CollectionID to use it:

    SELECT COL.Name AS 'Collection Name'  
    ,CASE (CR.RuleType)  
    WHEN '3' THEN 'Include'  
    WHEN '4' THEN 'Exclude'  
    WHEN '2' THEN 'Query'  
    WHEN '1' THEN 'Direct'  
    END AS 'Rule Type'  
    ,CR.ReferencedCollectionID AS 'Referenced Collection ID'  
    ,CR.QueryName AS 'Referenced Collection or Device Name'  
    FROM v_Collection COL  
    JOIN Collection_Rules CR ON COL.CollID = CR.CollectionID  
    where COL.CollectionID = 'XXXXXXXX'  
    

    And your issue is very strange, because if collection A is a member of collection B, the collection A will not be able to deleted.
    By the way, you are using SCCM 1702, it is not supported for a long time, it's recommended to upgrade to SCCM 2010 or 2103.


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.