Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » desired output format: CSV
desired output format: CSV [message #368383] Wed, 27 May 2009 09:46 Go to next message
Eclipse UserFriend
Originally posted by: daniel.strecker.gmx.net

Hi!

I'm trying to make the birt viewer output my data in CSV with one simple
link for automation.

I'm using tomcat and installed the birt viewer webapp. I can view the
report through the web browser and in the report, I can click the export
button and export the data to CSV format.
My problem now is that I'm not able to find a plain link which allows to
download the CSV file. I've used firefox with the Live HTTP Headers plugin
to sniff the POST-parameters of the HTTP-request and put them in as
GET-parameters in the URL. This works only if I also specify the sessionId
in the URL, which obviously doesn't work for automation, because when
invoking the same URL at a later time, the session with this ID won't
exist anymore.

I've read that it is possible to write an extension for BIRT which can
output CSV. But I do not understand why it should be impossible to output
CSV without this extension, since it seems to be that a dependency on an
existing session is the only problem. And I would prefer not to customize
my BIRT report viewer installation, because the report automation might
have to be used by others as well.


Thanks for any replies!
Daniel
Re: desired output format: CSV [message #368387 is a reply to message #368383] Wed, 27 May 2009 12:48 Go to previous message
Eclipse UserFriend
Originally posted by: daniel.strecker.gmx.net

It is possible with two successive URL requests to generate CSV data in an
easily scriptable fashion: You first have to request the frameset servlet
with __format=pdf and __document=documents/yourDocName.rptdocument and
afterwards request the extract servlet with the same parameters.

Requesting the frameset servlet before the extract servlet is necessary
because the extract servlet does not create the rptdocument, even not if
it does not exist. The extract servlet simply fails with the below error
message if the document does not exist:

org.eclipse.birt.report.service.api.ReportServiceException: The specified
name is not a file name. The FileArchiveReader is expecting a valid file
archive name.
at
org.eclipse.birt.report.service.ReportEngineService.throwDum myException(ReportEngineService.java:1053)
at
org.eclipse.birt.report.service.ReportEngineService.openRepo rtDocument(ReportEngineService.java:497)


I presume this behaviour of the extract servlet might be changed in future
versions to ease automating fetching CSV exports.
Previous Topic:MySQL Longtext datatype
Next Topic:Oraclethin.jar+Cripted DataSource
Goto Forum:
  


Current Time: Fri Apr 19 07:10:18 GMT 2024

Powered by FUDForum. Page generated in 0.02950 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top