SAP Knowledge Base Article - Public

1568443 - Crystal Report displays garbage values for date and time fields for reports based on Sybase database

Symptom

  • Crystal Reports displays date datatype as String in Crystal Reports designer
  • Crystal Reports displays garbage values
  • Date and Time fields from Sybase 15 database are shown as String

Environment

  • Crystal Reports 2008 Service Pack 3
  • Sybase ASE 15

Reproducing the Issue

Replication Steps:

On Sybase Database:

  1. Create a new table test with 2 columns t1 and t1 to display todays date and time. Run the below query: 
    create table test(t1 date , t2 time)
    insert into test values (getdate() , getdate())
  2. Now run the below query on Sybase> Interactive Config to check the results: 
    select t1, t2 from test

    Results are displayed on database are as below:
    t1 t2
    -- --
    2011-03-10 16:13:42

On Crystal Reports:

  1. Launch Crystal reports.
  2. Create a New blank report.
  3. Create a New Connection > Sybase Server > Add the details for the Sybase Server, Click OK.
  4. Choose the Test table > Click OK.
  5. From the Database Fields choose both the fields t1 and t2 drag to details section and Preview the report.

Note: This works with Sybase 12.5 Database

Cause

The issue has been identified and logged under Problem Report ID ADAPT01532821

Resolution

This issue is targeted to be fixed in Fix Pack 3.6 for Crystal Reports 2008 version.

Workaround:

  1. Create a ODBC System DSN
  2. Create a new Crystal Report using the ODBC connection pointing to Sybase database
  3. Add the table which has a date type field
  4. Go to Field Explorer and expand the table to see the fields
  5. Right click on a field and click on "Show Field Type"
  6. You can see the field datatype as date
  7. From the Database Fields choose the fields and drag them to details section
  8. Preview the report  

Keywords

KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Bug Filed

Product

Crystal Reports 2008 V1