Symptom
Error occurs when using Crystal Reports to retrieve data from Java Bean as:
Failed to retrieve data from the database.
Details: java.lang.IllegalArgumentException:Timestamp format must be yyyy-mm-dd hh:mm:ss[.fffffffff]
Environment
- SAP BusinessObjects Crystal Reports (CR) 2008
- Java Development Kit (JDK) 1.6.xx
Reproducing the Issue
- Follow the below SAP Knowledge Base Article (KBA) to create a Crystal reports which will use and pass a Timestamp type parameter to Java Bean data source:
- 1420614 - How to use a Java Bean as a datasource for Crystal Reports.
- Java Bean Connectivity document for information on creating a Java Bean and connecting to it in Crystal Reports.
- 1217404 - How to pass a parameter value to a Java Bean data source.
- Refresh the CR document and pick up a value from the calendar to pass the parameter.
- Error occurs: Failed to retrieve data from the database. Details: java.lang.IllegalArgumentException:Timestamp format must be yyyy-mm-dd hh:mm:ss[.fffffffff].
Cause
The Crystal Reports 2008 uses JDK1.6.xx.
Resolution
Change the JDK to 1.5.xx in the CRConfig.xml.
- Edit {Crystal Reports 2008 Install Home}\Common\4.0\java\CRConfig.xml.
- Find tag named <JavaDir>.
- Change the value to JDK 1.5.xx path.
Keywords
CR,yyyy-mm-dd,hh:mm:ss,[.fffffffff] , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Problem
Product
Crystal Reports 2008 V0