| Summary: | MVEL Dialect: BigDecimal does not show the correct value | ||
|---|---|---|---|
| Product: | [JBoss] JBoss Enterprise BRMS Platform 5 | Reporter: | Alessandro Lazarotti <alazarot> |
| Component: | BRE (Expert, Fusion) | Assignee: | Mario Fusco <mfusco> |
| Status: | VERIFIED --- | QA Contact: | Lukáš Petrovický <lpetrovi> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | BRMS 5.2.0.GA | CC: | mproctor |
| Target Milestone: | ER6 | ||
| Target Release: | BRMS 5.3.0.GA | ||
| Hardware: | Unspecified | ||
| OS: | All | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | Type: | --- | |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
VERIFIED fixed in ER7. |
Description of problem: MVEL does not show the correct value for BigDecimal instances Version-Release number of selected component (if applicable): BRMS 5.2.0.GA How reproducible: For a code like, BigDecimal someNumber = 500.01B; System.out.println(someNumber); The "someNumber" variable does not show the correct value Actual results: An integer value, 500. Expected results: The full floating point 500.01 Additional info: The same happens to show result of arithmetic operations btw BigDecimals: BigDecimal test = new BigDecimal("50000"); System.out.println(test / new BigDecimal("1.13")); The result is: 44247 ... instead of 44247.78761061946902654867256637168. Anyway, the internal representation is correct, only the method invoked to show the values is wrong. The result for: System.out.println( (test / new BigDecimal("1.13")) == 44247.78761061946902654867256637168B) is true.