I am new to java,I am trying to add the two BigDecimal values,
Please help some one,
How to add BigDecimal values.
Thanks in advance,
The API is good if you want to do precision mathematics, but let me give you an easier answer.
You can't add two BigDecimals together because that would be crashing two objects into each other, essentially. :-)
Your best bet is to take the .doubleValue() of each and add those together, since that method returns a primitive type that you can do arithmetic on.