Showing results for 
Show  only  | Search instead for 
Did you mean: 

Transform metric to string


Hi all,

I'm ingesting metrics via api (Metrics API v2).

So, I collect a state (string="OK") and in the script I change for a (integer = 1). The unit type im using is State.
Now in Dynatrace I would like to transform again the metric to string. I have multiple applications with various states so its hard to follow/memorize all the tansformations String<-->Integer.

The challenge that Im facing now is to show the state in a human readable way. I have to create alerts and generate a reasonable dashboard.

  1. Is it possible to convert the integer to string inside Dynatrace to generate friendly dashboards? (i have use cases with 10 states 😐)
  2. If (1.) its not possible I can use the problem app, but the state of application will be Red/Green.

Thanks all,


Dynatrace Champion
Dynatrace Champion

Hey RD,

In my example below I'm ingesting a metric thats random from 1-99 and has a device name as a dimension. You can then use partitions and a table view to display each dimension (in your case application) as being in a different state based on the last value.


The expression I used is as follows:



Hope this helps!

Thank you very much @Fin_Ubels, exactly what I needed 😁

Featured Posts