Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi Everyone.
I have two tables, and I need to append them based on a condition: where table 1 column 1 is not in table 2 column 2
Table 1
Column1 Column2
ABC 1
ABC 2
BCA 3
CZA 4
Table 2
Column1 Column2
ABC 1
BCA 2
ABC 3
Expected Output (after appending both tables):
Column1 Column2
CZA 4
Please provide me with the Power Query steps to achieve this."
Solved! Go to Solution.
Hi @Learner27 ,
I suggest you to try code as below in Power Query Editor.
let
Source = Table.Combine({#"Table 1", #"Table 2"}),
#"Filtered Rows" =
let
_Query =
Table.ToList( Table.SelectColumns(Table.NestedJoin(#"Table 1", {"Column1"}, #"Table 2", {"Column1"}, "Table 2", JoinKind.Inner),"Column1"),Combiner.CombineTextByDelimiter(","))
in
Table.SelectRows(Source, each not(List.Contains(_Query, [Column1])))
in
#"Filtered Rows"
New Table:
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Learner27 ,
I suggest you to try code as below in Power Query Editor.
let
Source = Table.Combine({#"Table 1", #"Table 2"}),
#"Filtered Rows" =
let
_Query =
Table.ToList( Table.SelectColumns(Table.NestedJoin(#"Table 1", {"Column1"}, #"Table 2", {"Column1"}, "Table 2", JoinKind.Inner),"Column1"),Combiner.CombineTextByDelimiter(","))
in
Table.SelectRows(Source, each not(List.Contains(_Query, [Column1])))
in
#"Filtered Rows"
New Table:
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Learner27
Regards
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
24 | |
9 | |
7 | |
6 | |
6 |
User | Count |
---|---|
29 | |
11 | |
11 | |
10 | |
6 |