I created an input control (single select query), I loaded data to the input control using a select query like the below.
select id,country from countries
My input control has country values displayed for example.
USA,CANADA,EUROPE,.....
once the user choose a particular country then I have to pass the "id" of that selected country to parameter used in the report.
I tried with different ways like the name of the report parameter exactly mapped with name of input control but nothing works.
Kindly provide me the steps to accomplish this since I am struggling for the past two days.
3 Answers:
Hi,
Create a parameter with the exact same id with the input control by right clicking 'parameters' and 'create parameter' in outline window. In input control, value column has to be set 'id' and visible column has to be set 'country'.
After that, you should add the parameter to your query in dataset. For example,
select * from Sales where countryid = $P{parameterName}