In most of the reports, we use multivalue parameters and for that we can directly write sql query in a separate data sets and modify the main dataset. It works fine for BIDS and Report Server for multi value parameters. But when we need to pass parameter values from the external portal to the reports then follow below steps:
1) Create a split function in your database (Many examples are available online)
2) Create a separate dataset for multivalue parameters
3) Change main dataset to populate multivalue parameter values from split function i.e: and (param1 in
(select column_value as param1 from table(HR.SPLIT(:Param1))) OR :param1 = ‘ALL’)
4) Go to the main dataset properties –> parameter –> select multivalue parameter expression –> add
this: =Join(Parameters!Param1.Value,”,”)
5) It should work now
2) Create a separate dataset for multivalue parameters
3) Change main dataset to populate multivalue parameter values from split function i.e: and (param1 in
(select column_value as param1 from table(HR.SPLIT(:Param1))) OR :param1 = ‘ALL’)
4) Go to the main dataset properties –> parameter –> select multivalue parameter expression –> add
this: =Join(Parameters!Param1.Value,”,”)
5) It should work now
For the URL populate multivalue paramter value list externally using sql query. I have also included 'ALL' as a value in a list
Ex: select distinct param1 from table1
where param1 is not null
union
select ‘ALL’ as param1 from dual
where param1 is not null
union
select ‘ALL’ as param1 from dual
Thank you
Comments
Post a Comment