Producing Multiple Report from one Report
<p>Hi,</p>
<p> </p>
<p>BIRT Newbie here,</p>
<p> </p>
<p>I am looking to be able to produce multiple reports from one report data source.</p>
<p> </p>
<p>The data source is XML and would need to print a separate report for each customer ID.</p>
<p> </p>
<p>can anyone help?</p>
<p> </p>
<p>Thanks,</p>
<p> </p>
<p>Mark</p>
<p> </p>
<p>BIRT Newbie here,</p>
<p> </p>
<p>I am looking to be able to produce multiple reports from one report data source.</p>
<p> </p>
<p>The data source is XML and would need to print a separate report for each customer ID.</p>
<p> </p>
<p>can anyone help?</p>
<p> </p>
<p>Thanks,</p>
<p> </p>
<p>Mark</p>
0
Comments
-
<p>Are you using commercial, or open source BIRT? What version?</p>
<p> </p>
<p>You'll need a driver report that can burst (create additional) reports. Have you seen these DevShares?</p>
<p> </p>
<p>For commercial:</p>
<p><a data-ipb='nomediaparse' href='http://developer.actuate.com/community/forum/index.php?/files/file/762-report-bursting-with-birt/'>http://developer.actuate.com/community/forum/index.php?/files/file/762-report-bursting-with-birt/</a></p>
<p> </p>
<p>For open source:</p>
<p><a data-ipb='nomediaparse' href='http://developer.actuate.com/community/forum/index.php?/files/file/630-burst-pdf-report-using-script/'>http://developer.actuate.com/community/forum/index.php?/files/file/630-burst-pdf-report-using-script/</a></p>
Warning No formatter is installed for the format ipb0 -
<blockquote class="ipsBlockquote" data-author="jsekhon" data-cid="147071" data-time="1489172156">
<div>
<p>Did not work.</p>
</div>
</blockquote>
<p> </p>
<p>Can you provide more details?</p>
<p> </p>
<p>What did not work? What version are you using? What did you try?</p>Warning No formatter is installed for the format ipb0 -
<p>Using Birt Luna 4.4.0.</p>
<p> </p>
<p>I used the same example with changed the paths . No bursted reports where generated.</p>
<p> </p>
<div>importPackage(Packages.org.eclipse.birt.report.engine.api);</div>
<div>var re = reportContext.getReportRunnable().getReportEngine();</div>
<div>var des = re.openReportDesign("c:\Burstreportfoldersfiles\burstdetail.rptdesign"); </div>
<div> </div>
<div>var ntask = re.createRunAndRenderTask(des);</div>
<div>ntask.setParameterValue("CustomerNumber", parseInt(this.getRowData().getColumnValue(0)) );</div>
<div>var options = new PDFRenderOption();</div>
<div>var outputfile = "c:\Burstingexample" + this.getRowData().getColumnValue(0) + ".pdf";</div>
<div>options.setOutputFileName(outputfile);</div>
<div>options.setOutputFormat("pdf");</div>
<div>ntask.setRenderOption(options);</div>
<div>ntask.run();</div>
<div>ntask.close();</div>0 -
<p>Hi,</p>
<p> </p>
<p>Couple of things you can try:</p>
<p> </p>
<p>1. Use forward slashes instead of backslashes in the openReportDesign method and the outputFile variable:</p>
<p>2. Remove the parseInt method in the setParameterValue method</p>
<p> </p>
<p>The following script works for me:</p>
<pre class="_prettyXprint _lang-">
importPackage(Packages.org.eclipse.birt.report.engine.api);
var re = reportContext.getReportRunnable().getReportEngine();
var des = re.openReportDesign("c:/xfer/burstdetail.rptdesign");
var ntask = re.createRunAndRenderTask(des);
ntask.setParameterValue("CustomerNumber", this.getRowData().getColumnValue(0));
var options = new PDFRenderOption();
var outputfile = "c:/xfer/test" + this.getRowData().getColumnValue(0) + ".pdf";
options.setOutputFileName(outputfile);
options.setOutputFormat("pdf");
ntask.setRenderOption(options);
ntask.run();
ntask.close();
</pre>
<p>Hope this helps,</p>
<p> </p>
<p>P.</p>
Warning No formatter is installed for the format ipb0 -
<p>I also had to change the CustomerNumber from String to Int in the detail report to get it to work.</p>
Warning No formatter is installed for the format ipb0
Categories
- All Categories
- 107 Developer Announcements
- 53 Articles
- 104 General Questions
- 141 IM Services
- 43 OpenText Hackathon
- 32 Developer Tools
- 20.6K Analytics
- 4.1K AppWorks
- 8.9K Extended ECM
- 898 Cloud Fax and Notifications
- 76 Digital Asset Management
- 9.3K Documentum
- 29 eDOCS
- 118 Exstream
- 39.8K TeamSite
- 1.7K Web Experience Management