fredericoschmitz20 Posted April 23, 2013 Share Posted April 23, 2013 Hello,i have a main report with a sql query, how i can use those query results in a subreport without executing the query again? Thank you. Link to comment Share on other sites More sharing options...
Ankur Gupta Posted May 9, 2013 Share Posted May 9, 2013 Hi, If you want to use the value of the main report query in the subquery you need to , map those fields to pass on to the parameters in the subreport and when the query runs it will automatically send the values to the subreport and there would be no need to run it twice. In a single go job will be done. For mapping the values to the subreport- 1. First create the dummy parameters in the subreport which would recieve the values from the main report .2. Click on the subreport element in the main report.3. Then you need to set the connection as Use a connection Expression4. Then you need to set the expression to $P{REPORT_CONNECTION}5. Then you need to add the parameter Have explained the above in a jpg file. refer to it for more clearificationI hope this helps to resolve your query. Regards,Ankur 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