Vikram SE
Vikram SE

Reputation: 297

SSRS Multivalued parameter

I have a report in ssrs 2008 r2.I have created two multi-valued parameter on my report like fiscal period (value is 08,09,10,11) and parentname(in which there are multiple parent like a,b,c,d...).A user can select single value or multiple value of his choice.I have create seprate dataset for each to populate its value.Both have datatype 'Text'.

Now uderlying query is something like this:

selet * from table where fiscal period in(@fiscalperiod) and parentname in(@parentname)

If I run this query manually in sql then I wrote query like

select * from table where fiscalperiod in('09','10') and parentname in('a','b''c')

Now my question is Is ssrs run the dataset query of report in this way like 'a','b''c' that means comma seprated value.

Upvotes: 1

Views: 368

Answers (1)

Yogesh
Yogesh

Reputation: 3482

Since Parameter is multi-valued, Query will be run like 'a','b','c'

selet * from table where fiscal period in(@fiscalperiod) and parentname in(@parentname)

If you select fiscal period: 08, 09 and parentname: a, b then query will be executed internally like

selet * from table where fiscal period in('08', '09') and parentname in('a', 'b')

Upvotes: 1

Related Questions