SAP Knowledge Base Article - Public

1304630 - Date Field not showing the same format in JRC web-application as in Crystal Report for Eclipse designer

Symptom

  • Report displays date fields created using parameters in 'mm/dd/yyyy' format in Crystal Report for Eclipse (CR4E) designer.
  • Report displays the same fields in mm/dd/yy format while trying to view the report through a web application, using JRC API's.

Reproducing the Issue

  1. Create a report in CR4E Designer using JDBC(JNDI) connection:
    1. Create a parameter field for the date field in crystal report designer.
    2. Using the date parameter field, create formula fields to be used in report header for the date range.
    3. Place the date fields in report header and in the details section.
    4. Refresh the report.
    5. Report displays date fields in 'mm/dd/yyyy' format.
  2. Create a web application and run the report using JRC SDK.
  • JRC version : JRC XIR2
  • Application Server : Tomcat 5.0

Cause

In designer the format for the date field is System Long default in the properties window.

dateShilpi.JPG

Resolution

  1. Right click on the fields in the designer.
  2. Click properties from the list.
  3. Change the date field format in the properties window to mm/dd/yyyy.
  4. Run the report through a JRC web-application.

Keywords

KBA , BI-DEV-JAV , BI Software Development Kits (SDKs) - Java , Problem

Product

Crystal Reports, version for Eclipse 1.0