Query Details

Intune Enrollment Successby Enrollment Type

Query

//Enrollment Success by Enrollment Type
IntuneOperationalLogs
| where  OperationName == "Enrollment" 
| where Result == "Success" 
| extend myJson=todynamic(Properties)
| extend EnrollmentType = tostring(myJson ["EnrollmentType"])
| summarize OperationCount=count() by EnrollmentType 
| sort by OperationCount desc

Explanation

This query is analyzing logs from Intune, specifically focusing on successful enrollment operations. Here's a simple breakdown of what it does:

  1. Filter for Enrollment Operations: It starts by selecting only the log entries where the operation name is "Enrollment."

  2. Filter for Successful Results: It further narrows down the data to only include entries where the result of the operation was "Success."

  3. Extract Enrollment Type: It converts the 'Properties' field into a dynamic JSON object and extracts the 'EnrollmentType' from it, converting it into a string.

  4. Count by Enrollment Type: It counts the number of successful enrollment operations for each type of enrollment.

  5. Sort Results: Finally, it sorts these counts in descending order, so the enrollment types with the most successful operations appear first.

In summary, the query provides a ranked list of different enrollment types based on how many successful enrollments each type has had.

Details

Rod Trent profile picture

Rod Trent

Released: July 10, 2020

Tables

IntuneOperationalLogs

Keywords

IntuneOperationalLogsEnrollmentSuccessTypePropertiesOperationNameResultJsonCount

Operators

whereextendtodynamic()tostring()summarizecount()sort by

Actions

GitHub