Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

How to take filtered range of cells from a column and append to another column in the same table?
03-04-2023
05:52 PM
I have a table similar to the one shown below:
Col A | Col B | Condtion X |
A123 | A322 | 1 |
A322 | A300 | 0 |
A232 | A123 | 1 |
What I want to do is filter on Condition X where value is 0 and then append the corresponding Col B values to Col A for the same table. The result will look like below:
Col A | Col B | Condtion X |
A123 | A322 | 1 |
A322 | A300 | 0 |
A232 | A123 | 1 |
A300 | - | - |
Basically, I am adding to Col A the values that are in Col B but not already in Col A.
I want to do this in Power Query (M code) NOT Dax
Hope that makes some sense.
Thanks in advance
Solved! Go to Solution.
1 ACCEPTED SOLUTION

Anonymous
Not applicable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2023
11:54 AM

@zb134 There may be a more streamlined way to do this without duplicating the table, but off the top of my head I used the following steps:
- Load the table
- Make a duplicate of the table
- Filter the duplicate table on Condition X = 0
- Remove Column A and Column X from the duplicate table
- Rename Col B in the duplicate table to Col A
- Append the duplicate table to the original table
1 REPLY 1

Anonymous
Not applicable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2023
11:54 AM

@zb134 There may be a more streamlined way to do this without duplicating the table, but off the top of my head I used the following steps:
- Load the table
- Make a duplicate of the table
- Filter the duplicate table on Condition X = 0
- Remove Column A and Column X from the duplicate table
- Rename Col B in the duplicate table to Col A
- Append the duplicate table to the original table

Helpful resources
Featured Topics
Top Kudoed Authors (Last Month)
User | Count |
---|---|
101 | |
84 | |
81 | |
54 | |
46 |