Investigations NQL examples

This list of query examples is designed to help you perform successful investigations in the Nexthink web interface. Go through the investigations listed below and pick the one most similar to the investigation you’re trying to complete. Copy the query and adjust it to your use case.

Query device tables

chevron-rightGet total incoming traffic for outlook.exe in the past 7d for all devices.hashtag
devices
| include execution.events during past 7d
| where binary.name == "outlook.exe"
| compute total_incoming_traffic = incoming_traffic.sum()
| list device.name, device.entity, total_incoming_traffic
chevron-rightFind out if there have been frequent system crashes in the past hour, for example, if >2% devices had a crash in last 24h.hashtag
devices during past 24h
| include device_performance.system_crashes
| compute system_crash_count= number_of_system_crashes.sum(), crashing_devices= device.count()
| summarize ratio_of_devices_crashing= crashing_devices.sum() * 100 / count() , total_system_crashes= system_crash_count.sum()
chevron-rightList all devices that need a memory upgrade.hashtag
devices during past 7d
| include device_performance.events during past 7d
| compute used_memory_ = event.used_memory.avg(), used_memory_percentage= event.used_memory.avg()*100/device.hardware.memory.avg()
| where used_memory_percentage> 75
| list device.name, device.entity, device.hardware.model, device.hardware.type, device.operating_system.name, device.hardware.memory, used_memory_, used_memory_percentage
chevron-rightCount the number of devices that need a memory upgrade and do a breakdown of devices by hardware manufacturer.hashtag
devices during past 7d
| include device_performance.events during past 7d
| compute used_memory_ = event.used_memory.avg(), used_memory_percentage= event.used_memory.avg()*100/device.hardware.memory.avg()
| where used_memory_percentage> 75
| summarize c1 = count() by hardware.manufacturer
chevron-rightList devices with low disk space.hashtag
devices
| with device_performance.events during past 124h
| compute free_space_on_system_drive = system_drive_free_space.avg()
| where free_space_on_system_drive < 2000MB
chevron-rightRetrieve devices. List all devices with the Nexthink Collector package installed.hashtag
chevron-rightRetrieve devices. List all devices without the Nexthink Collector package installed.hashtag

Query other tables

chevron-rightRetrieve installation events. List all uninstallation of a specific package across all devices.hashtag
chevron-rightRetrieve packages. List all packages starting with the ones installed on most devices.hashtag
chevron-rightRetrieve packages. List all packages starting with the ones installed on fewest devices.hashtag
chevron-rightRetrieve packages. List packages installed on fewer than 5 devices but installed on at least one device.hashtag
chevron-rightList the number of system crashes grouped by error label for the crash.hashtag
chevron-rightCount the number of active devices over time, i.e. during past 7 days.hashtag
chevron-rightGet the history (14d) of number of devices with low disk space.hashtag
chevron-rightGet crashes statistics per binary.hashtag
chevron-rightGet crashes statistics for selected binary on the timeline.hashtag
chevron-rightCompute the average usage time of an application per user per day by departments.hashtag
chevron-rightCount campaign responses by campaign and by state to understand campaign progress.hashtag
chevron-rightRetrieve binaries from the past 7 days. Summarize them by category and subcategory.hashtag
chevron-rightRetrieve binaries from the past 7 days. Summarize them according to the Accessibility category and the Vision Accessibility subcategory.hashtag
chevron-rightRetrieve users from the past 7 days. List them according to usage time equal or over 30 minutes for binaries under the Development Tools category and the Code Editors and IDEs subcategory.hashtag

Last updated

Was this helpful?