Solved

SSRS 2008 Multi Value Parameter Filter using OR

Posted on 2016-11-11
3
20 Views
Last Modified: 2016-11-14
Hello experts -

I am trying to use a multi value parameter to filter two different fields in a tablix. However, SSRS does not allow me to specify OR when adding filters. For example, the user selects options in the multi valued parameter and then those choices are used to filter two different fields in an OR statement

Parameter: 'Choose Event Type:' [user selects] J, R

I want the tablix to return all rows with a Start Event of J, R OR all rows with an End Event of J, R

In the attached example, I would want rows 10, 24, and 25 to be returned.

I originally had one filter setup to use for both fields but abandoned that in favor of two fields, please see the attached screen shot of SSRS.

Thank you.

-- Lisa
SSRS-Multi-Value-Example.xlsx
Filters-in-SSRS.JPG
0
Comment
Question by:ldcallahan
  • 2
3 Comments
 
LVL 28

Accepted Solution

by:
Ryan McCauley earned 500 total points
ID: 41885347
You can't use an OR statement using the interface like you're suggesting, but you can still do it - it just requires you write the OR statement as a single filter condition and then check if it's a valid row inside the formula. If it is, you can set the "output" of your formula to 1 and then just have the filter check if the value is 1 before deciding to filter the row.

If that's confusing or doesn't make sense, I can add an example later.
0
 

Author Closing Comment

by:ldcallahan
ID: 41886263
Thanks. I actually realized that as well but am glad for the external validation :)

I actually ended up writing a split function that produces a table in SQL and then joining the result set to that. It works great and actually saves a bit of processing time.
0
 
LVL 28

Expert Comment

by:Ryan McCauley
ID: 41887290
I've done that as well - I wish there was a more graceful way to handle OR and multi-value parameters, but I'm glad you found a method that gets the job done!
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Time Corrections for Reports Working with a report, we made some interesting discoveries about the time corrections/updates We are using the following Parameters: Starting Entered Date (Date) formatted as Data type: "Date/Time" Ending Entered …
A recent question popped up and the discussion heated up regarding updating a COMMENTS (TXT) field in a table using SSRS. http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/MS-SQL_Reporting/Q_27475269.html?cid=1572#a37227028 (htt…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now