Skip to main content

Hello Team,

I have amount field that can have values like below 

123.450

123.400

123.456

123.000

I have to remove the trailing zeros and the result should be like below:

123.450 = 123.45

123.400 = 123.4

123.456 = 123.456

123.000 = 123

Can you please help here.

 

 

 

 

https://regex101.com/r/mD7gK4/7


@Sumit.K7 , thanks for the response. Just one thing here, when the input is 1.0, we need response as 1 instead of 1.0


Use this : Replace text matching following regex with empty values

\.?0+$

https://regex101.com/r/lKmsde/1


Hi @Ankith K 

Checkout below solution,

Note: In Replace With add a space by keying in space bar from your keyboard

 


Thank you guys for your prompt support, this really helped. 


Thank you guys for your prompt support, this really helped. 

Amazing @Ankith K 


Reply