Dynamic Device Group Rule for Marketing Name
Short answer
C Use the -contains operator to match devices with 'Marketing' in their display name.
Question
Key Takeaways
This question tests knowledge of Azure AD dynamic group membership rule operators, specifically distinguishing between substring matching (-contains) and exact/in-list matching (-in).
Learn how to create a dynamic device group in Microsoft Intune that matches devices containing 'Marketing' in their name. This page establishes the correct syntax using the -contains operator without wildcards.
Common mistake: Users often incorrectly use the -in operator with wildcards or add asterisks to the -contains operator, which is not valid syntax for this context.
Expert Analysis
Why the Answer Is Correct
The correct syntax for filtering by a substring in a dynamic group is using the -contains operator directly on the property value. The expression (device.displayName -contains "Marketing") correctly identifies any device where the display name includes the word "Marketing" anywhere within the string.
Why the Other Options Are Wrong
Option A uses -in, which expects a list of exact values, not a substring search. Option B incorrectly combines -in with wildcard characters, which are not supported in this manner. Option D adds unnecessary wildcards to the -contains operator; the operator inherently checks for inclusion, so adding * makes it invalid syntax.
Community Comment Notes
Community members confirm that -contains is the standard approach for substring matching. As one user noted, "C is correct" referencing official documentation, while others emphasized that wildcards are not needed with -contains.
Official Reference
https://learn.microsoft.com/en-us/entra/identity/users/groups-dynamic-membership
This link opens the official vendor documentation in a new tab.
Exam Strategy
Memorize the specific operators used in Azure AD dynamic groups: -eq for equality, -ne for not equal, -contains for substrings, and -in for lists of exact values. Do not mix them with SQL-style wildcards.
Frequently Asked Questions
Why can't I use wildcards like *Marketing*?
What is the difference between -contains and -in?
Community Votes
100% of anonymous learners picked answer C. Votes are pick records left by other test-takers — they are not the verified answer.
Discussion 3 contributions
Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.
From public community threads 3
-
Moot2 👍 2 Answered CC is correct https://learn.microsoft.com/en-us/entra/identity/users/groups-dynamic-membership
-
Meek_Learner 👍 1 Answered C• The -contains operator checks if a string includes a specific substring, regardless of whether the letters are uppercase or lowercase. For example, it would find "Marketing" in "Marketing Department", "marketing_team", and "Sales & Marketing". • You’re looking for the substring "Marketing" (no wildcards needed). The -contains operator automatically checks if this string is part of the device name.
-
HvD 👍 2 Answered CAgreed
Reader comments & corrections
No reader corrections yet — spotted an error or have a note? Share it below.
Related Analysis
Practice All MD-102 Questions
Access 92 questions with complete answers and detailed explanations.
View Full MD-102 Practice Test →