Jump to content
We've recently updated our Privacy Statement, available here ×

Passing field values between reports


neha_rabaadia

Recommended Posts

hi

I am having problem with ireport. I made a query in my main report which returns a set of rows. I want to pass the result of main report in the subreport. Subreport also contains a query which needs result of the main report. I am getting a field expression $F{emp} containing the values. How to pass this field value to subreport. I have tried with assigning field expression to a parameter and then passing this parameter to subreport properties.

But in the report it generates null.

what is the solution for this or any other solution for passing the values between reports. I am using iReport 3.0.

Thanks

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

firstly, click on the subreport, look at the properties palette, near the bottom is a parameters property. Add the parameters that you need. Keep the names exactly the same from the main report and the sub report... ie don't even change the case, if the subreport has the many COMPANY_ID as the field then the passed parameter must be COMPANY_ID, cannot be Company_ID ... Two different variables. Hope this helps.

Regards

Aubrey

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...