[#10131] - Inconsistency with Label marks in JasperSoft 6.3.2

Category:
Bug report
Priority:
Normal
Status:
Confirmed
Project: Severity:
Feature
Resolution:
Open
Component: Reproducibility:
Always
Assigned to:
0

Background:
Since we faced several issues with JasperSoft 6.4, the Technical Support team recommended us to use 6.3.2 in order to avoid the bugs in 6.4.

The reason why we use the newer JasperSoft versions is because of the Custom Visualization component such as HTML5 Charts since we want to create Dashboards in Studio and publish them to the web server.

Problem:
The issue is the inconsistency with the label mark which results into following error message "java.math.BigDecimal cannot be cast to java.lang.String".

Reproducibility:
Go to...
Palette --> Custom Visualization --> HTML5 Charts --> Edit Chart properties --> Chart Data --> Configuration.

Once you go to Configuration, you can add Measures.

E.g. you add the measure "Clicks" to your chart which is a numeric value.
In the "Measure" window you add a Label Expression which would be "Clicks" or $F{Clicks. However, the value remains java.lang.Long.

Once you save it and run the chart in the Preview, you will face the error message that java.math.BigDecimal cannot be cast to java.lang.String.

This is an inconsistency in the software since a label expression is required. Once you add the label expression, it causes an error message.

Solution:
In order to not face the error, go to Measures-> Modify-> Value definition -> Label Expression -> E.g. $F{Field name}.toPlainString()(for an example have a look at the screenshot attached below).
The label expression is cast into a String but the value still remains numeric (e.g. java.lang.Long).
However, the need to add the expression "....toPlainString()" should not be there since a label expression needs to be automatically recognized as a String and accepted as such.

v6.3.1
Jaspersoft® Studio
minschka's picture
Joined: Oct 18 2016 - 1:37am
Last seen: 2 years 10 months ago

1 Comment:

#1
  • Status:New» Confirmed
Feedback