It finds one text string that exists inside another text string and returns the position within the second string, from which the first one begins. It is NOT case-sensitive and allows wildcard characters.
For case-sensitive search use the FIND function.
The syntax of the function is the following:
SEARCH(find_text, within_text, [start_num])
find_text: The text you are searching for.
within_text: The text containing the text you are searching for.
[start_num]: Optional. The starting position within the string of the within_text argument, from which the search will begin. The default value is 1 (the first character of the within_text string).
If find_text is an empty string SEARCH returns the start_num of the search.
If find_text is not found then the #VALUE! error is returned.
If start_num is less than or equal to zero, or if it is greater than the length of the within_text string then the #VALUE! error is returned.
You can use the wildcard characters, question mark (?) and asterisk (*), in criteria. If you want to find an actual question mark or asterisk, type a tilde (~) before the character.
Click on the button to practice using this function, with the help of our Online Assessment Tool:
Here is an example of how to use the SEARCH function:
In the cell Α2 calculate the position of the word TEST4U inside the text of the A1 cell, when it is followed by any letter and the next letter is the letter Ο.