List.ContainsAny Function in Power Query
The List.ContainsAny function returns true if any item in given values is found in the input list, false otherwise. An optional equation criteria value, equationCriteria, can be specified to control equality testing.
Syntax
List.ContainsAny(list as list, values as list, optional equationCriteria as any) as logical
Example:
Power Query M
let source = {"India", "America", "Canada", "Japan", "Australia", "England", "China"}, return = List.ContainsAny(source, {"Canada", "Nepal"}) in return
The output of the above code is true.
Example:
Power Query M
let source = {"India", "America", "Canada", "Japan", "Australia", "England", "China"}, return = List.ContainsAny(source, {"Bhutan", "Nepal"}) in return
The output of the above code is false.