DAX function
SEARCH / FIND — DAX function reference
Position of a substring.
Syntax
dax
SEARCH(<find_text>, <within_text>, [<start_num>], [<NotFoundValue>]) FIND(<find_text>, <within_text>, [<start_num>], [<NotFoundValue>])
Examples
dax
SEARCH("@", [Email], 1, BLANK())→ A number
dax
IF(SEARCH("Pro", Product[Name], 1, 0) > 0, "Pro line", "Standard")→ Flags products whose name contains "Pro", case-insensitively
Checks for a dash using the case-sensitive FIND instead of SEARCH.
dax
FIND("-", Product[SKU], 1, 0) > 0→ true / false
Common mistakes & gotchas
- SEARCH is case-insensitive; FIND is case-sensitive. Pass a fourth argument to avoid an error when not found.
- SEARCH is case-insensitive and supports wildcards (? and *); FIND is case-sensitive and does not support wildcards — picking the wrong one is a common source of missed or unintended matches.
- Both return an error if find_text isn’t found and no NotFoundValue is supplied — always pass a 4th argument (commonly 0) rather than relying on IFERROR, since that’s cheaper and clearer.
Related DAX functions
From Text