14 May 2024
03:16 PM
- last edited on
23 May 2024
02:52 PM
by
Michal_Gebacki
Hello,
If you use a metric expression to get a ratio together with a default(0) option like:
var_total:default(0)/var_part:default(0)
Dynatrace will, if there is no measurement, do a 0/0! this will result in a "does not exist".
so you better use an extra default(0) to correct this?
KR Henk
Solved! Go to Solution.
04 Jun 2024 08:34 PM
Hi henk_stobbe,
To avoid the 0/0 error you mentioned, you can use the default(1) option in the denominator instead of default(0). This way, if there is no measurement, the denominator will be 1, and any number divided by 1 will be that same number, while 0 divided by 1 will be 0 and will not cause an error.
Here is how you can adjust your metric:
var_total:default(0)/var_part:default(1)