sreeharsha Posted July 5, 2013 Share Posted July 5, 2013 Hi all,I have a report with a query to get orders information including order_id,I have to use this order_id to get the multiple rows from another table, If I join these two tables than I am getting multiple rows of order table.I wanted to write a sub report to get the sub table data in the sub report query by sending the order id to the sub report. But since this is very costly, I cant do it.I was suggested to created a datasource of the subtable by sending all the order ids to a query and use this datasource to fill the sub report.Can some one please guide me on how to create the datasource by sending all the order ids to a query and how to use this datasource to fill the sub report. Link to comment Share on other sites More sharing options...
lucianc Posted July 5, 2013 Share Posted July 5, 2013 You could have the query with the join (and order by order_id), create a group in the report for $F{order_id}, print the order details in the group header and the subrows in the detail band.Regards,Lucian Link to comment Share on other sites More sharing options...
ajinkya_c Posted July 8, 2013 Share Posted July 8, 2013 Hi,The group by band is a one way as lucianc explain, another way i think you can handle it on query level.If you want to use subreport then create parameter of your order_id in main report and map it with order_id of subreport with parameter map expression in subreport properties.RegardsAjinkya 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