# How to get max KEY:VALUE per event.id without using expand (JSON array)

**URL:** <https://community.dynatrace.com/t/how-to-get-max-key-value-per-event-id-without-using-expand-json-array/52323>\
**Category:** DQL\
**Tags:** dql, business-analytics, notebooks\
**Created:** [July 3, 2025, 4:34am UTC](https://community.dynatrace.com/t/how-to-get-max-key-value-per-event-id-without-using-expand-json-array/52323 "2025-07-03T04:34:14Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![tracegazer](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/tracegazer/32/32785_2.png) [@tracegazer](https://community.dynatrace.com/u/tracegazer)\
**Post date:** [July 9, 2025, 3:00pm UTC](https://community.dynatrace.com/t/how-to-get-max-key-value-per-event-id-without-using-expand-json-array/52323/3 "2025-07-09T15:00:55Z")

</div>

Hi, your comment was really helpful — I found a way to iterate through the array, which I honestly had no idea how to approach before, but your DQL example pointed me in the right direction.

```markup
| parse rs.body_result, """JSON_ARRAY:parsed_json_elements"""
| fieldsAdd array(parsed_json_elements[][broadcast_time]), alias: MAX
| fieldsAdd arraySize(parsed_json_elements), alias: COUNT_MAX

```

Thank you, I really appreciate it!

---

_[View the full topic](https://community.dynatrace.com/t/how-to-get-max-key-value-per-event-id-without-using-expand-json-array/52323)._
