SAP Knowledge Base Article - Public

1723307 - How to show database value ‘0’ as NULL in Crystal Reports Designer

Symptom

How to convert database value ‘0’ as Null in Crystal Reports

Environment

  • Crystal Reports 2008
  • SAP Crystal Reports 2011
  • SAP Crystal Reports 2013

Resolution

  1. Create a blank formula(it should not contain anything) in Crystal Report Designer and name it as Empty_formula
  2. Create another formula using the code: IF{Field_value} = 0 THEN {@Empty_formula} ELSE Totext({Field_value},0000)
  3. Place it in the designer.
  4. Make sure "Convert Null values to Default" is unchecked in File > Report Options

See Also

For more information see What is Null and Why is it Important for Crystal Reports

Keywords

Convert 0 to null, zero to null, print null values, Crystal Reports , KBA , BI-RA-CR , Crystal Reports designer or BusinessViews Manager , How To

Product

Crystal Reports 2008 V1 ; SAP Crystal Reports 2011 ; SAP Crystal Reports 2013