aetherflux Posted January 19, 2008 Posted January 19, 2008 I have an XML datasource that I want to use to generate parameters... however, this datasource isn't in a file, it's in the "Parameter" column of the ReportCriteria table of the database that is currently the active JDBC connection. Is there a way to get iReport to somehow parse this data without re-writing my code to create a new XML file every time the report is run?
justis Posted January 19, 2008 Posted January 19, 2008 I think you would have to do some sort of strange join to that table and get it included as part of your report query. Perhaps you could have all your reports be subreports and the outer report performs the query to get your settings. Either way seems like a jury-rigged solution. Most likely, your needs will be best met by building your own datasource before you fill the report. You could write a servlet (or whatever paradigm is appropriate for your environment) that queries the database twice, builds a single XML datasource (in memory, no need to spool to disk) and passes that to JasperFillManager as its datasource. Best of luck. Kind regards,Justis
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now