FIND Function
The FIND function enables you to identify the starting position of one text string within another text string. It returns the position of the first character of the text your searching for within the second text. The search is case sensitive.
Syntax
FIND(find_text, within_text, [start_num])
Arguments
Argument
Description
Find_text
Required. This is the text you want to find.
Within_text
Required. This is the text containing the text you want to find.
Start_num
Optional. This argument specifies the point, in characters, from which you want to start the search in within_text . The first character in within_text is character number 1. If you omit this argument it will start from the first character in within_text .
Example 1
In this example, we use the FIND function to return the position of different characters in the string “United States”. As you can see from the results, the FIND function is case sensitive.
Example 2
The FIND function is most useful when used with another string function in Excel. For example, let’s say we want to extract the first part of a reference number like NWTBGM-21. We can use FIND to locate the position of the divider and use the LEFT function to extract the part of the reference we want.
=LEFT(A2,1,FIND("-",A2,1)-1)
FIND returns the position of “-", which is 7 in this case. We need to subtract 1 from this number to remove the divider from the part of the string we’re interested in. The LEFT function then uses 6 as the starting point to return the characters in the string starting from right to left. See the section LEFT, RIGHT Functions in this book for more on the LEFT function.