Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Unable to Multiply 2 BigDecimal Columns

Hi All,

 

I am trying to multiply 2 Big Decimal Variables using the following command:

 

row6.Quantity.multiply(row6.LineAmount)

 

But it is giving the error.

 

Exception in thread "main" java.lang.Error: Unresolved compilation problems:

 

Both Quantity and LineAmount are BigDecimal types.

 

Labels (2)
1 Reply
Anonymous
Not applicable
Author

The command is fine. If you are testing the the expression using "Test" this will happen because there is no value attached to the columns. If you try this in the expression, it will work as the values are hardcoded and therefore able to be tested...

 

(new BigDecimal(3.0)).multiply((new BigDecimal(2.0)))

Don't worry about this so much. Just run the job if you want to test it with some actual data.