Symptom
- Error: "Failed to retreive data from Database"
- In Crystal Reports, when trying to refresh a report based on XML, the following error occurs:
"Failed to retreive data from Database"
Environment
- SAP Crystal Reports 2020
- SAP Crystal Reports 2025
Reproducing the Issue
- In Crystal Reports, create a new report based on XML with large data using the XML and Webservices connection.
- Refresh the report
- After some time, it displays the error: "Failed to retreive data from Database"
Cause
XML driver uses Java. The memory allocated to the JVM is not large enough to handle the large number of records.
Resolution
Increase the memory for the Java Virtual Machine (JVM) used for the XML connection:
- Close Crystal Reports.
- On the computer where Crystal Reports is installed, navigate to the location of CRConfig.xml file
Default file path: C:\Program Files (x86)\SAP BusinessObjects\SAP BusinessObjects Enterprise XI 4.0\java\ - In a text application like Notepad, open the file: CRConfig.xml
- For the option: JVMMaxHeap, increase the value for the memory, like:
<JVMMaxHeap>512000000</JVMMaxHeap> - For the option: JVMMinHeap, also incrase the value for the memory, like:
<JVMMinHeap>256000000</JVMMinHeap>
- Save the CRConfig.xml file
- Start Crystal Reports, and re-open the report.
- Refresh the report, and it will refresh successfully. But if you are still receiving an error, increase the JVM memory to a larger value.
Keywords
cr, failed to retreive data, crystal report, cr, xml, javaheap, jvm , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Problem
Product
SAP Crystal Reports 2020 ; SAP Crystal Reports 2025
SAP Knowledge Base Article - Public