Forum Discussion

Simaant's avatar
Simaant
Frequent Visitor
2 years ago

Filter data and from one table based on data another table and create a slicer from the second table

Hi, I have two tables. One of the text columns in the first table (A) has text values which are codes separated out by commas. The second table, B, has all of these distinct codes that form the entire column of table A, in rows of table B.

There is no relationship between the tables as there isn't a common ID, you can say Table B is a lookup table with the codes and the description.

My end goal is to have a slicer created from that code column from table B and it filters the visuals and data which are mainly created using table A.

eg: if one of the code in table B is 'Z36', one or more than one of the rows in that code column of table A  could have 'Z36' by itself, or 'Z36', 'H12', or any combination with no limit on the number of codes for that row. I want to filter the data in table A such that for every occurence of that selected code from the slicer from table B, that occurence of that code fromtable A gets filtered and the visuals change accordingly.

 

Thank you!

3 Replies

  • selimovd's avatar
    selimovd
    Most Valuable Professional

    Hey Simaant ,

     

    what did you try so far to solve it? Where are you struggling?

     

    Isn't that the same problem as in this post:

    https://community.fabric.microsoft.com/t5/Desktop/How-to-filter-selection-if-it-is-contained-in-Row-of-column/m-p/3708152#M1208123

     

    Check the uploaded solution file, I think that is what you need.

     

    If you need any help please let me know.
    If I answered your question I would be happy if you could mark my post as a solution โœ”๏ธ and give it a thumbs up ๐Ÿ‘

    Best regards
    Denis

    Blog: WhatTheFact.bi
    Follow me: twitter.com/DenSelimovic
    Connect with me: LinkedIn

    • Simaant's avatar
      Simaant
      Frequent Visitor

      Hi selimovd , Thank you so much for your prompt response. This looks like the closest solution to my problem and I'm going to give it a try here, Let me get back to you with an answer, i'm hopeful this will work. 

      • Simaant's avatar
        Simaant
        Frequent Visitor

        selimovd sorry about the late response, but I tried it and i'm stuck at the step where I have to use a delimiter. My code column in table A just has values separated by commas. However, the number of values in there can be dynamic (can be 2 or can be as large as 50, separated by commas). I used the split by delimiter function but somehow it is just allowing me to create just one additional and isnt creating columns equal to dynamic columns with max being max number of values in the code column. I think the B-G use case you explained is not applicable in my case, I'm just trying the rest of the solution