# Adding a DQL filter

**URL:** <https://community.dynatrace.com/t/adding-a-dql-filter/41790>\
**Category:** Dashboarding\
**Tags:** dashboards\
**Created:** [September 27, 2023, 9:14am UTC](https://community.dynatrace.com/t/adding-a-dql-filter/41790 "2023-09-27T09:14:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jamz](https://avatars.discourse-cdn.com/v4/letter/j/b9bd4f/32.png) [@Jamz](https://community.dynatrace.com/u/Jamz)\
**Post date:** [September 27, 2023, 9:14am UTC](https://community.dynatrace.com/t/adding-a-dql-filter/41790/1 "2023-09-27T09:14:52Z")

</div>

I have JVM dashboard and I want to get rid of an extra GC process that shows in the dashboard,

I’ve created a filter using the DQL but I get a warning

 ![Jamz_0-1695806051427.png](https://global.discourse-cdn.com/dynatrace/original/3X/0/1/01477f277fa02eb28cadaaa9f9ee530a95c22992.png)

Does anyone know what this is?  
"dimension Key has been referenced, but the metric has no such key

---

<div class="post-metadata">

**Author:** ![victor\_balbuena](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/victor_balbuena/32/9773_2.png) [@victor\_balbuena](https://community.dynatrace.com/u/victor_balbuena)\
**Post date:** [September 27, 2023, 9:20am UTC](https://community.dynatrace.com/t/adding-a-dql-filter/41790/2 "2023-09-27T09:20:37Z")

</div>

I think you’re confusing terms here, what you’re using in your screenshot is a&nbsp;[metric selector](https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/metric-selector), which doesn’t use DQL. Inside that metric selector, you’re using a filter which follows the syntax \<dimension, value\> where dimension is the metric dimension to filter by and value if the value used to filter that dimension. The value seems to look fine, as it’s an entity selector that selects some specific process group instances. However, the dimension is wrong as the metric **builtin:tech.jvm.memory.gc.suspensionTime** does not have a dimension with value&nbsp; **builtin:tech.jvm.memory.gc.suspensionTime**. Instead, your filter should look like: filter(and(or(in( **“dt.entity.process\_group\_instance”** ,\<value\>), since&nbsp; **dt.entity.process\_group\_instance** is an actual dimension of the metric.
