Andolasoft Inc
Andolasoft Inc

Reputation: 1296

Dynamically Cascading parameter from iReport to JasperReports Server by reading data from database table

I am creating new input control on "Input control details" tab for "Type". Then i choose Multi-select list of Values and click on button Edit local Resource (List Of Values). There i have entered values manually.

Is it possible to enter the list values dynamically.

Means i want to display the order numbers in the dropdown list for the list values dynamically from the ORDER table instead of entering them manually

My query is - "SELECT `ORDER_NUM` FROM `ORDER`"

Please suggest. Thanks in advance.

Upvotes: 0

Views: 606

Answers (1)

axsoverflow
axsoverflow

Reputation: 23

In your "Repository Navigator", create a folder eg "Resources" in this folder create a "Query" for example "Query01". Configure this application with your information.

Always in your "Repository Navigator", create in the "Input controls" local input control file. In the "Input control details" tab, select the type of control and options. For example, "Multi-select List of Values ​​(Check box)." Then "Query Resource" in the tab "Input control details" choose "From the Repositery" select your previously created query.

Then in your report, go to Parameters and create "Query01". In the application of your report, call your "Query01" via the SQL query like this:

WHERE $ X {IN, Your.Table, Query01}

I just understand myself how this works as I struggled to understand at first. Hoping to have quite do the clearing.

Upvotes: 1

Related Questions