# How to calculate Average of "Response Time", Please help me with query?

**URL:** <https://community.dynatrace.com/t/how-to-calculate-average-of-response-time-please-help-me-with-query/47389>\
**Category:** DQL\
**Tags:** dql\
**Created:** [August 29, 2024, 4:16pm UTC](https://community.dynatrace.com/t/how-to-calculate-average-of-response-time-please-help-me-with-query/47389 "2024-08-29T16:16:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dynatracer1218](https://avatars.discourse-cdn.com/v4/letter/d/bcef8e/32.png) [@Dynatracer1218](https://community.dynatrace.com/u/Dynatracer1218)\
**Post date:** [August 29, 2024, 4:16pm UTC](https://community.dynatrace.com/t/how-to-calculate-average-of-response-time-please-help-me-with-query/47389/1 "2024-08-29T16:16:58Z")

</div>

Hi,

I am trying to write query to get “Response Time” Average. I am getting Null, when I ran the below query. Can someone please help me on how to calculate the Average of “Response Time”?

 ![Dynatracer1218_0-1724948034455.png](https://global.discourse-cdn.com/dynatrace/original/3X/e/e/eefef8d623dc052c30b42735f82c28fee51e2040.png)

 ![Dynatracer1218_1-1724948119117.png](https://global.discourse-cdn.com/dynatrace/original/3X/e/4/e4869441031d76aef3e12cdd5c4a2d1f561493ef.png)

Thanks in Advance!

---

<div class="post-metadata">

**Author:** ![jaume\_reverte](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/jaume_reverte/32/1479_2.png) [@jaume\_reverte](https://community.dynatrace.com/u/jaume_reverte)\
**Post date:** [August 29, 2024, 4:25pm UTC](https://community.dynatrace.com/t/how-to-calculate-average-of-response-time-please-help-me-with-query/47389/2 "2024-08-29T16:25:48Z")

</div>

Hello,

For what you are sharing can be that Dynatrace is detecting the value as a String. To check the type use type(ResponseTime) and if it is a String then change it to Number using asNumber(ResponseTime).
