0

So there is a lot of stuff about using SSRS parameters to select multiple values but nothing about using both a parameter and a fixed value using the in select statement.

So what I'm trying to do is this:

select * from table where id in (Parameter_1, 'total')

Yet when I do that it complains its can't find 'Parameter_1'.

I've gotten another report to work when its just:

select * from table where id = Parameter_2

but this this isn't good enough in this use case.

0

Ok the problem was actually with the parameter itself.

I had to create a new one in the query called @Parameter_1 and then set it up in the query parameter tab and delete the old one.

Really confusing.

0

Kindly create a stored procedure to do this task and pass values from ssrs to avoid multiple execution plans.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.