Discussions
Categories
Choose a Product
THRUST SERVICES
CORE APPS
CE PRODUCTS
...
Quick Links
POPULAR
HELPFUL TIPS
Groups
My Links
FOR SIGNED IN MEMBERS:
Back to website
Home
Designing Analytics Reports
How to set row prefetch size with BIRT API
Migrateduser
<p>Hi,</p>
<p> </p>
<p>I am using BIRT 4.4.2. I'm generating a report using DE API. My report uses a OdaDataSourceHandle object to retrieve data from an Oracle database. My query returns only one row, but has many columns, so when I run my report, I get the following error:</p>
<p>SEVERE: <strong>There is insufficient memory to execute this report</strong>.</p>
<p> </p>
<p>I googled a lot, and found that in the Eclipse Designer, there is a property binding to set on the dataSet, named "row fetch size", that can solve this memory issue. But as I said, I'm not using the eclipse designer, but instead I'm coding my report in full java.</p>
<p> </p>
<p>I couldn't find how to set row fetch size property in full Java. Can someone give me the piece of code to set the row fetch size property on a dataSet with Design Engine API?</p>
<p> </p>
<p>Here is how I initialize my dataSource:</p>
<p> </p>
<p><b>final</b> OdaDataSourceHandle dsHandle = factory.newOdaDataSource(databaseName, "org.eclipse.birt.report.data.oda.jdbc");</p>
<p> </p>
<p>dsHandle.setProperty("odaDriverClass", driverName);</p>
<p>dsHandle.setProperty("odaURL", url);</p>
<p>dsHandle.setProperty("odaUser", user);</p>
<p>dsHandle.setProperty("odaPassword", password);</p>
<p> </p>
<p>I also use this:</p>
<p> </p>
<p><b>final</b> DataEngine dataEngine = DataEngine.<i>newDataEngine</i>(config, <b>null</b>);</p>
<p><b>final</b> OdaDataSourceDesign odaDataSource = <b>new</b> OdaDataSourceDesign(DATASET_NAME);</p>
<p><b>final</b> OdaDataSetDesign odaDataSet = <b>new</b> OdaDataSetDesign(DATASET_NAME);</p>
<p> </p>
<p>odaDataSource.setExtensionID("org.eclipse.birt.report.data.oda.jdbc");</p>
<p>odaDataSource.addPublicProperty("odaURL", url);</p>
<p>odaDataSource.addPublicProperty("odaDriverClass", driverName);</p>
<p>odaDataSource.addPublicProperty("odaUser", user);</p>
<p>odaDataSource.addPublicProperty("odaPassword", password);</p>
<p> </p>
<p> </p>
<p>Thanks a lot for your support</p>
<p> </p>
Find more posts tagged with
Comments
There are no comments yet