Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi,
I have the following columns in my data:
ID Label1 Label2
123 GREEN, YELLOW BLUE,RED
456 ORANGE GREEN
456 GREEN PURPLE
456 RED BLUE
456 RED YELLOW
What I am trying to do is combine filters so to speak, for example
Filter #1: Label1 contains GREEN or YELLOW
Filter #2: Label2 contains GREEN or YELLOW
This would results would be:
123
456 (Where Green is in Label2)
456 (Where Green is in Label1)
456 (Where Yellow is in Label2)
Solved! Go to Solution.
I was able to solve it doing the following:
1) Select both columns
2) Drop down one of the columns and do "Text Filters" and click on "Advanced"
Now it allows to select multiple columns.
Hi @EaglesTony, try this.
Now you can just filter value 1 in [Keep Row] column.
Result
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjQyVtJRcg9ydfXTUYh09fHxDwfynXxCXXWCXF2UYnWilUxMzYBC/kGOfu6uILVFqal5SBJgvUA6IDQowMcVSQKkH2IUhiDUothYAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [ID = _t, Label1 = _t, Label2 = _t]),
Ad_KeepRow = Table.AddColumn(Source, "Keep Row", each
[ a = Text.SplitAny([Label1], " ,") & Text.SplitAny([Label2], " ,"),
b = if List.ContainsAny({"GREEN", "YELLOW"}, a, Comparer.OrdinalIgnoreCase) then 1 else 0
][b], Int64.Type)
in
Ad_KeepRow
I was able to solve it doing the following:
1) Select both columns
2) Drop down one of the columns and do "Text Filters" and click on "Advanced"
Now it allows to select multiple columns.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
15 | |
12 | |
8 | |
8 | |
7 |
User | Count |
---|---|
15 | |
13 | |
9 | |
7 | |
6 |