Forum Discussion
Need correction in M query to join two tables based on pattern
Hi All,
I want to join two tables to get the result using a pattern table in the Power query.
This is my source table with Publisher, version, and tech name values.
and I want to join the joining table to get the Technology value.
The joining should be done under the conditions that the
The values in the 'Publisher' field should be equal on both tables and
The values in the 'Version' field in the source table should start with the value in the Joining table and
The values in the 'Tech Name' in the source table should contain the values in the 'Tech Name Contains' field and
The values in the 'Tech Name' in the source table should not contain the values in the 'Tech Name should not contains' field.
The result should be like this
I'm having the code for this join but it will work if the 'Tech Name should not contains' only have a single value in a cell.
I need help to join the table with the condition that a cell can have more than one value with any delimiters.
and this is my code
Thanks
2 Replies
- AnonymousNot applicable
Hi Pbi_newuser2994 ,
You could first split the 'tech name should not contains' then unpivot the columns of splitted.
Then merge two table to match the values.
Please refer to
Power Query - Matching a value from a list using power Query - Microsoft Community
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Pbi_newuser2994New Member
Hi, Anonymous Thanks for your reply. I can understand your solution but I'm permitted 1 row for 1 pattern.
Is there any other way we split and use it in a single cell?