Highlight cells with conditional formatting that contain word from another table

I want the table “Overview” to highlight every cell in the “Description” column, which contains a word out of the “Basket”. I tried the formulas Contains, ToList and RegexMatch but didn’t get the desired outcome yet.

Something along these lines:

Basket.Any(thisRow.Description.Find(CurrentValue.Fruit) != -1)

The coda.io formula documentation is hard for discoverability, nothing to note that a string is also a collection or at least inherits the extensions method/traits, and no search ability - perhaps this could be a public coda doc with community comments instead :wink:

You could also chain Lower() such as thisRowDescription.Lower().Find(… and CurrentValue.Fruit.Lower() if you wanted case insensitive matching

1 Like

Thank you Matt_Freeman. I actually just found a working solution with thisRow.Description.Lower().RegexMatch(Join("|",Basket.Fruit).Lower()) which also seems to work.

1 Like