Symptom
- If a report created in Crystal Reports contains a boolean parameter, and that parameter is used in a section formatting formula similar to "NOT({?Param1})", then when that report is viewed in Crystal Reports for Eclipse, it generates the error:
ERROR com.businessobjects.reports.sdk.JRCCommunicationAdapter - detected an exception: Exception in formula '{@-suppressSection-0}' at '({?Param1})':
The type of the value returned does not match the type of the field.
at com.crystaldecisions.reports.dataengine.h.if(SourceFile:460)
at com.crystaldecisions.reports.dataengine.h.a(SourceFile:320)
at com.crystaldecisions.reports.dataengine.DataContext.a(SourceFile:523)
at com.crystaldecisions.reports.dataengine.DataContext.getValue(SourceFile:466)
at com.crystaldecisions.reports.dataengine.DataProcessor2.getValue(SourceFile:1892)
... - This error occur whether you allow the viewer to prompt for the parameter, or you pass the parameter value in code.
Environment
- Crystal Reports for Eclipse 12.2.227
- Crystal Reports for Eclipse 12.2.228
Reproducing the Issue
- In Crystal Reports, create a report with a boolean value parameter.
- Use that parameter in a section formatting formula.
Cause
- Product defect.
Resolution
- Issue resolved in SAP Crystal Reports, version for Eclipse SP29
- A workaround:
- Use a numeric parameter instead, and in the section formatting formulas use "IF {?Param1} = 0 then false else true"
Keywords
CR for Eclipse , KBA , BI-DEV-JAV , BI Software Development Kits (SDKs) - Java , Problem
Product
Crystal Reports, version for Eclipse 2.0