SAP Knowledge Base Article - Public

2509542 - Crystal Report formula doesn't get fully evaluated when a null value is passed to a parameter

Symptom

If a crystal report formula assigns a parameter value to a variable and the parameter has a null value, then the remainder of the formula does not get evaluated.

e.g.

... Beginning Formula Text ...
MyVariable = {?MyParameter}
... More Formula Text ...

If MyParameter is a null value, then the "More Formula Text" portion of the formula would not get evaluated.

Environment

  • Crystal Reports Designer 2008
  • Crystal Reports Designer 2013

Resolution

To resolve this issue, add a check for null before assigning the value to the variable.

e.g.

if (not(isnull({?MyParameter}))) then
MyVariable = {?MyParameter}
endif

Keywords

formula evaluate null , KBA , BI-DEV-JAV , BI Software Development Kits (SDKs) - Java , BI-RA-CR , Crystal Reports designer or BusinessViews Manager , Problem

Product

SAP Crystal Reports XI