SAP Knowledge Base Article - Public

1475309 - How to retrieve only null values when parameters are used in Crystal Reports

Symptom

Cannot retrieve only null values.

Environment

Crystal Reports (CR) 2008 only.

Reproducing the Issue

  1. Create report with a parameter.
  2. Refresh the report.
  3. Assign no value to the parameter in the 'Enter Parameter Values' dialog box.
  4. Select 'OK'.

Resolution

  1. Open the Report menu in CR.
  2. Select 'Selection Formula'.
  3. Choose 'Record'.
  4. Type the following record selection formula: 

    IF (not HasValue({?Optional_Parameter})) THEN IsNull({Field_with_NullValues}) ELSE {?Optional_Parameter}={Field_with_NullValues}

See Also

Knowledge Base article 1473287 - Error: 'the value is not valid' when a null value is entered in the parameter dialog box in Crystal Reports

Keywords

list of values, entry, empty, '...' , LOV  , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , How To

Product

Crystal Reports 2008 V0 ; Crystal Reports 2008 V1