# Dashboards with multiple aggregations

**URL:** <https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313>\
**Category:** Dashboarding\
**Tags:** dynatrace-managed, dashboards-classic\
**Created:** [November 18, 2021, 2:59am UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313 "2021-11-18T02:59:45Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![gfishman](https://avatars.discourse-cdn.com/v4/letter/g/a8b319/32.png) [@gfishman](https://community.dynatrace.com/u/gfishman)\
**Post date:** [November 18, 2021, 2:59am UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/1 "2021-11-18T02:59:45Z")

</div>

I had a support ticket because I tried to have a chart on a dashboard with average and 90% values of the same custom metric, but they both would not display at the same time.&nbsp; Was told that I needed to put them on two separate charts.

They should be allowed on the same chart - other combinations of avg, max, and count are allowed.

---

<div class="post-metadata">

**Author:** ![Babar\_Qayyum](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/babar_qayyum/32/13620_2.png) [@Babar\_Qayyum](https://community.dynatrace.com/u/Babar_Qayyum)\
**Post date:** [November 18, 2021, 7:41am UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/2 "2021-11-18T07:41:58Z")

</div>

Hello&nbsp;[@gfishman](https://community.dynatrace.com/user/11224)

I just gave it a try with one of the built-in metrics and it works together for both aggregations. What type of custom metric do you have?

 ![Babar_Qayyum_0-1637221196107.png](https://global.discourse-cdn.com/dynatrace/original/3X/6/e/6e192b5c38ecf1732907d3d4cd6c5822878b80c1.png)

Regards,

Babar

---

<div class="post-metadata">

**Author:** ![gfishman](https://avatars.discourse-cdn.com/v4/letter/g/a8b319/32.png) [@gfishman](https://community.dynatrace.com/u/gfishman)\
**Post date:** [November 18, 2021, 2:08pm UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/3 "2021-11-18T14:08:51Z")

</div>

It’s a response time on a calculated service metric, for Database Service Type filtered on a particular sql statement

---

<div class="post-metadata">

**Author:** ![zietho](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/zietho/32/41733_2.png) [@zietho](https://community.dynatrace.com/u/zietho)\
**Post date:** [November 30, 2021, 3:40pm UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/4 "2021-11-30T15:40:42Z")

</div>

Hey&nbsp;[@gfishman](https://community.dynatrace.com/user/11224),

can you please provide more details because as&nbsp;[@Babar\_Qayyum](https://community.dynatrace.com/user/22017)&nbsp;points out that should work Could you maybe send me your support ticket?

regards

Thomas

---

<div class="post-metadata">

**Author:** ![gfishman](https://avatars.discourse-cdn.com/v4/letter/g/a8b319/32.png) [@gfishman](https://community.dynatrace.com/u/gfishman)\
**Post date:** [November 30, 2021, 9:41pm UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/5 "2021-11-30T21:41:04Z")

</div>

Support ticket

> **[Home | Dynatrace Support Portal](https://support.dynatrace.com/)**

---

<div class="post-metadata">

**Author:** ![zietho](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/zietho/32/41733_2.png) [@zietho](https://community.dynatrace.com/u/zietho)\
**Post date:** [July 20, 2022, 9:51pm UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/6 "2022-07-20T21:51:47Z")

</div>

Sorry, I missed your reply! I have checked your referenced ticket and triggered a review of it internally with the backend team responsible because I don’t understand why it should be possible with all other metrics but not with the one you’re using. I’d argue that’s a bug! In the meantime, have you tried to do plot it again? So is it still happening that you don’t see it? Just to be sure.

Again, I am sorry for missing your reply!

regards

Thomas

---

<div class="post-metadata">

**Author:** ![stemos](https://avatars.discourse-cdn.com/v4/letter/s/74df32/32.png) [@stemos](https://community.dynatrace.com/u/stemos)\
**Post date:** [July 21, 2022, 8:16am UTC](https://community.dynatrace.com/t/dashboards-with-multiple-aggregations/33313/7 "2022-07-21T08:16:54Z")

</div>

The issue is not that Dynatrace cannot chart both values at the same time. The issue is that the values are identical. Let me explain.

Unless configured otherwise in the Code mode tab, the Data Explorer performs a space aggregation on the metric datapoints. After applying such a space aggregation in Dynatrace, you can use all [available aggregations](https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/metric-selector#aggregation) on the transformed data. In many cases, this behavior is reasonable, but there are pitfalls.

For example, consider a counter metric that natively only supports the aggregation value. The metrics has the dimension host and the following values per host:

| | timeslot1 |
| --- | --- |
| HOST-1 | 1 |
| HOST-2 | 5 |
| HOST-3 | 2 |

After applying a space aggregation, the per host values are merged and you can chart the min (= 1), the max (= 5), the sum (= 8), the avg (=&nbsp;2.66) and so on. Also the percentiles are calculated based on the three values. Reasonable, isn’t it?

In contrast, let’s assume there is only the series for HOST-1 available and no additional series/dimensions. After applying the space aggregation, you can again apply all aggregations. However, as there is only one series, the space aggregation does in fact not aggregate any values. Consequently, the values for avg, min, max, sum as well as the percentiles are the same (i.e., 1 for the example above).

The issue is also described on the&nbsp;[Metrics API FAQ page](https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/metric-faq#unexpected-aggregations).
