Need to modify an rptDesign file before execution
#1
Posted 14 February 2012 - 08:54 AM
I'm using Actuate Java Components, specifically the Actuate Deployment Kit war file to run reports.
I've customized the web.xml of the war to specify a STANDALONE_REPOSITORY_PATH and the webapp is picking up the files from the directory specified in the configured location.
Now I'd like to change the query in the canned .rptdesign file BEFORE the report is run.
I *think* I'll be able to find the java API to manipulate the report before it is run. The question I have even before I do that is, how can I find the point in the code of the webapp where the report is launched from, so that I can intercept the call and change the query.
I was hoping that I will be able to drop a customized jar in WEB-INF/lib that will have my code to do this. Is this the correct approach? Is there some documentation that talks about this kind of integration?
Thanks!
#2
Posted 14 February 2012 - 09:47 AM
You can use scripting to dynamically change the query in the report without modifying the report design file, here is an example:
http://www.birt-exch...y-modification/
Ashwini
#3
Posted 14 February 2012 - 10:53 AM
Thanks for the pointer.
But I was (and I should have mentioned this in my post) looking for a Java solution.
Is there anyway I can get the canned.rptdesign file, manipulate it using the *java* api, save it to the same repository location and then let the war launch it as it was going to before interception?
Thanks!
averma, on 14 February 2012 - 09:47 AM, said:
You can use scripting to dynamically change the query in the report without modifying the report design file, here is an example:
http://www.birt-exch...y-modification/
Ashwini
#4
Posted 15 February 2012 - 03:57 PM
You could use BIRT design engine API for modifying a design file dynamically. Here is the link to some more details and examples:
http://www.eclipse.o...gnEngineAPI.php
Here is link to some a developer guide if you wish to integrate the above into report execution aspects:
http://www.birt-exch...opers-guide.pdf





MultiQuote




