mwarner_2 Posted October 20, 2016 Share Posted October 20, 2016 I have a report with a table component (for export to Excel).Also the report has a No Data section, to show the user if they made input control selections that result in no data being returned. This section has an error message as well as their selections. So the way Jaspersoft handles this sort of a report: it first quieres the database in the Main Report, to see if there is any data. If not it goes to the No Data handling.If there is data, then the table component is run, which results in a second query to the dataset.This is at least twice as inefficient as it should be.Is there any way to make this work with only one query to the database? Link to comment Share on other sites More sharing options...
narcism Posted October 21, 2016 Share Posted October 21, 2016 Please post some sample JRXML illustrating your issue. Link to comment Share on other sites More sharing options...
VimMang Posted October 26, 2016 Share Posted October 26, 2016 However I did not get any answer yet. but the workaround is have two queries needs to be written although in first query use TOP 1 records instead of all records. Link to comment Share on other sites More sharing options...
narcism Posted October 26, 2016 Share Posted October 26, 2016 If the 2 queries are exactly the same, then maybe you do not need to use a list(with a subdataset and the same query as the main one). You could have the contents of the list placed directly in the detaild band. But we are just guessing here. That's why we need a sample JRXML to work on. Link to comment Share on other sites More sharing options...
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