I’m struggling trying to create a simple report using a foundset calculation as a field in the report. I can access other foundset fields, including related values, but no success with calculations. Jasper tells me it can’t find the field.
Is it possible someone send an example of a xml jasper report with a calculated field from a foundset.
Servoy version 5.1.0 - build 956.
Jasper plugin version 3.0.1a1.
I’m using Jasper + Native Servoy Object only in one specific scenario where we want to generate a dynamic parameterized report from Servoy. Thus, the report is generated at runtime, we build the XML ourselves. I need to pass a foundset because it already includes the filtered records I want to display.
I’ve tried to use calculations as a normal field, but it doesn’t work. I get the following error:
java.lang.Exception: Error evaluating expression :
Source text : $F{iscommenced_jobheader}
Error evaluating expression :
Source text : $F{iscommenced_jobheader}
Wrapped java.lang.Exception: Error evaluating expression :
Source text : $F{iscommenced_jobheader} (C:\Projects\workspace_tsmseven\reports\globals.js#64)
at C:\Projects\workspace_tsmseven\reports\globals.js:64 (rep_runGridReport)
Is there any example of using calculations in a report?
I found the problem myself. My reports were missing the attribute - language=“groovy” - in the jasperReport tag. For instance this is the way it should be: