Passing Parameters From Crosstab Report to Drill-Down Report In Jasper Studio
Scenario: I have created a crosstab report and When user clicked on measure it should open a another details report by passing the same parameters being selected in crosstab report
Prerequisites:
Jasper Studio Workbench
Jasper Server
Database: Postgres – Foodmart
Make data easy with Helical Insight. Helical Insight is world's best open source business intelligence tool.
Click Here to Free Download
Main Report
- Created a cross tab report having Region and area as row groups, month wise store cost, sales units as measures with Region and Area as parameters
- Created Region and Area parameters in main report section
- Create same parameters inside the cross tab
- While creating parameters in crosstab, if you are facing any issue then add parameters from source code
<crosstabParameter name=”Region” class=”java.util.Collection”/
<crosstabParameter name=”Area” class=”java.util.Collection”/>
Drill Down Report
- Create a detailed report having few columns and add region, area and month as parametersCase: Whenever user clicked on a measure in the main report, it should take respective region, area and month values and it should render drill down report with selected values.
- Add Hyperlink properties to measures in the cross tab main report
Click on element, in properties pane click on hyperlink, change values of link target to blank and link type to reportExecution. Click on parameters and add parameters.
Make data easy with Helical Insight. Helical Insight is world's best open source business intelligence tool.
Grab The Free TrailAdd drill down report path in _report and region, area and month parameters
- Run the report in interactive mode and check click icon will be displayed on the measures and click on that. It should open drill down reportHyperlinks are displayed in blue color. Click on measure it will open drilldown report but selected input control parameters values are not passing from main report to subreportTo handle this case, we have to add one property in main cross tab reportClick on crosstab element in outline pane, Open properties and click on crosstab
There is one attribute named as Parameters Map Expression.
Enter $P{REPORT_PARAMETERS_MAP} inside the expression
Save and run the report.
Now Click on measure hyperlink, it will load drill down report
Main Report – Cross tab
– Clicked on Sales column in January Month, CA area and USA Region
Drill down report
– Getting January, CA and USA as parameters from the main report
Make data easy with Helical Insight.
Helical Insight is the world’s best open source business intelligence tool.
- Create a detailed report having few columns and add region, area and month as parametersCase: Whenever user clicked on a measure in the main report, it should take respective region, area and month values and it should render drill down report with selected values.
Best Open Source Business Intelligence Software Helical Insight is Here
A Business Intelligence Framework
Thanks,
Ramu Vudugula
BI Developer