MD-102 Manage and maintain devices Practice Question
Exhibit
Get-IntuneManagedDevice -Filter "(operatingSystem eq 'Windows') and (lastSyncDateTime lt '2025-01-01T00:00:00Z')"
Refer to the exhibit. A Microsoft Graph PowerShell cmdlet retrieves devices. What is the purpose of this query?
⚠ Common exam trap
Test-takers frequently confuse `approximateLastSignInDateTime` with `enrolledDateTime`, leading them to incorrectly select Option C, which refers to enrollment date instead of last sync date.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
To find Windows devices that have not synced since before January 1, 2025
The query uses Get-MgDevice with a filter on approximateLastSignInDateTime being less than 2025-01-01T00:00:00Z. This filter retrieves devices whose last approximate sign-in occurred before January 1, 2025, indicating they have not synced since that date. The -and operator with deviceId -ne $null ensures only actual devices (not null device IDs) are returned. Option D correctly identifies this as finding devices that have not synced since before January 1, 2025.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
To find Windows devices that are compliant
Why it's wrong here
Compliance state is exposed through the isCompliant property, not through an operating system filter, so this query cannot return compliant devices. It tempts because compliance reporting is a common Graph task, and would be correct if the filter compared isCompliant rather than operating system values.
- ✗
To find Windows devices with an operating system version earlier than 2025
Why it's wrong here
The query filters on operatingSystemVersion, which compares version strings, not enrolment timestamps, so it cannot return devices enrolled before a date. It tempts because version and date filters look similar in Graph syntax, and would be correct when targeting outdated builds such as Windows 10 21H2.
- ✗
To find Windows devices enrolled before January 1, 2025
Why it's wrong here
Enrolment date is held in the enrolledDateTime property, not in any operating system field, so this filter cannot select devices by enrolment date. It tempts because both properties appear in device objects, and would be correct if the cmdlet filtered on enrolledDateTime instead.
- ✓
To find Windows devices that have not synced since before January 1, 2025
Why this is correct
The query filters the device collection by operating system and last sync timestamp, returning only Windows devices whose approximateLastSyncDateTime predates 1 January 2025. This identifies stale Windows devices that have not checked in since that date, matching the stated purpose.
Go deeper
Related to this question
About these practice questions
One of 556 original MD-102 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This MD-102 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the MD-102 exam.