Forum Discussion
Partial match and return value across two tables
Hi team,
I have the data in following two tables where i want to match phone numbers in one of the column without country code with another column in a different table that contains phone number and country code together. I was envisioning an approach that uses Text.End function based on the length dynamically.
Table A
| Phone Number |
| 9823456789 |
| 9923456788 |
| 9022334455 |
Table B
| Phone (with country code) | id |
| 19022334455 | 3344 |
| 919923456788 | 3311 |
Final Output
| Phone Number | id |
| 9823456789 | null |
| 9923456788 | 3311 |
| 9022334455 | 3344 |
- Anonymous3 years ago
You could use add a column like:
Table.AddColumn(TableOrPriorStepName, "NewValues", each Table.FindText(TableB, [Phone Number]))
--Nate
3 Replies
- AnonymousNot applicable
You could use add a column like:
Table.AddColumn(TableOrPriorStepName, "NewValues", each Table.FindText(TableB, [Phone Number]))
--Nate
- AnonymousNot applicable
Hi Anonymous
Thanks for your response. It works but can we please improve performance by specifying a column in TableB?
- AnonymousNot applicable
You can try this:
Table.AddColumn(TableOrPriorStepName, "NewValues", each Table.FindText(TableB[[Phone (with country code)id]], [Phone Number])
--Nate