reporting services - Getting multiple integer values in an SSRS parameter -
how multiple integers value field of ssrs parameter can use in statement in clause?
bear me. think end simple syntax question explanation overlong.
i have report want split between 2 types of staff dedicated , bureau. way determine which hour activation occurs, dedicated staff working hours except 12 , 13 (midday 2pm).
i've created parameter called @agenttype , added clause in sql query
where [hour] in (@agenttype)
i set data type of parameter integer , set available values in picture.
this works test if try model working hours accurately
ssrs removes commas , turns interger 1234567... tried using expresion =1,2,3... caused errors when report ran.
so question how multiple integers value field of ssrs parameter can use in statement in clause?
this solution work you. can create 2 parameters, agenttype
, agenttypehidden
.
for agenttype
set 2 available values follows:
agenttypehidden
must hidden , set allow multiple values:
don't set available values default values using expression:
=iif( parameters!agenttype.value=1, split("1,2,3,4,5,6,7,8,9,10,11,14",","), split("12,13",",") )
also set always refresh
agenttypehidden
parameter.
finally in query use agentypehidden
parameter.
where [hour] in (@agenttypehidden)
let me know if helps.
Comments
Post a Comment