Forum Discussion

MTracy's avatar
MTracy
Icon for Advocate I rankAdvocate I
8 years ago
Solved

Need way to measure/filter with multiple values in multiple columns

I've been using PBI for a few months now through self-training (videos, blogs, articles, and this forum).   I'm stuck on how to create a way to filter my data table (let's call that table 'CP') based...
  • Greg_Deckler's avatar
    8 years ago

    This might be a situation where you could employ the "disconnected table trick". I just published a blog article on it here:

     

    https://community.powerbi.com/t5/Community-Blog/Solving-Attendance-with-the-Disconnected-Table-Trick/ba-p/279563

     

    What I am thinking is that you could have a disconnected table of all of your codes and use measures that employ SEARCH or FIND that return true/false based upon whether you can find/search the particular code in each column.

     

    This may not be the way to go.

     

    An alternative and perhaps better approach would be to use Power Query to pivot/unpivot your data such that each item has as many rows as codes. So, you would have something like:

     

    Column, Column1, Column2, Code

    blah, blah, blah, PJ

    blah, blah, blah, PZ

    blah, blah, blah, TC

    foo, foo, foo, YT

    foo, foo, foo, PJ

    foo, foo, foo, TC

     

    Then a standard slicer *should* do the trick.