1
votes

I'll describe my question using an oversimplified, hypothetical example.

Let's say I have a text column with a bunch of random words in it. I want to make a new True/False column based on whether or not a word in that row contains the letter A. I can use the following DAX formula:

ContainsA = IF((SEARCH("A",Table[Words],,0))>=1,TRUE(),FALSE())

So, if you're here looking for a solution to this problem, this does work. My question is this:

Is there a better way to do this? Surely there must be some DAX function that returns True/False directly, right?

1

1 Answers

2
votes

Try the CONTAINSSTRING function.

ContainsA = CONTAINSSTRING ( Table[Words], "A" )