29 Apr 2022 09:47 AM - last edited on 19 Oct 2022 06:37 AM by MaciejNeumann
I'm having trouble extracting a value from a java method for request attribute.
to put it simple:
the value extracted : 100.000
the value we need : 100000 (without the '.')
I'm trying to use regex to clean this up, but with no success
For example ([^\.]*+) returns 100 instead of 100000
Solved! Go to Solution.
In reality, I believe your regex should return a list of two results, 100 and 000
The same will happen with similar regexs, eg. (\d+)
While it seems pretty easy, I believe it is not, as I have not been able to come up with one that works for all applicable values...
Have you managed to solve this? I have a similar problem with the comma
sadly not yet...
best of luck and if you get the regex, please post it here.
This does not have a solution with the regex extraction, since you need to extract two parts (before and after the point).
How can that be solved? I need to remove the comma to be able to add all the fields.The field I have is called totals. I need to get a report where I can add up all the sales. 583,100 with that format it doesn't let me add, that's why I need to remove the comma
No, it's not possible to solve it. You need either two capture groups or do a replacement. None of these is available in request attribute cleanup rules.
Depending on the source of your request attribute, it is possible it can be obtained by other means (without the point/comma character). In general, this cannot be solved using the cleaning rules in Dynatrace.