powerquery

Compare two fields with Text contains


I have two tables (table1 and table2). I want to perform an inner merge query with both tables.enter image description here

I want to check if the parttial name field in table1 is found in table2 may be by using Text.Contains. I am not quite familiar with this.

Any help please please please.


Solution

  • To test if table1.Name is contained within a row of table2.Lookup Value:

    in table1, add column ... custom column ... with formula:

    = List.AnyTrue(let a=[Name] in List.Transform(Table2[Lookup Value], each Text.Contains(_,a)))