Keep trailing zero when serializing BigDecimal to JSON #4667
caodangtinh
started this conversation in
General
Replies: 2 comments 6 replies
-
Issues are for bugs. So far, this appears just to be a usage question. Have you tried pattern = "#.0"? I don't know for definite but BigDecimal formatting should be handled by this class And its Javadocs describe how the pattern values like '#' and '0' work. |
Beta Was this translation helpful? Give feedback.
5 replies
-
One way to serialize with trailing zero without needing
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Describe your Issue
Is there any way to keep the trailing zero value when serializing BigDecimal to JSON? I'd expect something like
But I always get
I have already tried with
And a customer, JsonSerializer
But it is still produce the same output.
Beta Was this translation helpful? Give feedback.
All reactions