beautypg.com

Apple iWork '09 User Manual

Page 321

background image

Chapter 11

Text Functions

321

Examples

=SEARCH(”ra”, “abracadabra”) returns 3; the first occurrence of the string “ra” starts at the third
character in “abracadabra”.
=SEARCH(”ra”, “abracadabra”, 5) returns 10, the position of the first occurrence of string “ra” when you
start looking at position 5.
=SEARCH(“*card”, “Wildcard”) returns 1, since the asterisk at the beginning of the search string
matches all the characters before “card”.
=SEARCH(“*cad”, “Wildcard”) returns an error, since the string “cad” does not exist.
=SEARCH(“?card”, “Wildcard”) returns 4, since the question mark matches the one character
immediately preceding “card”.
=SEARCH(“c*d”, “Wildcard”) returns 5, since the asterisk matches all the characters between the “c” and
“d”.
=SEARCH(“~?”, “Wildcard? No.”) returns 9, since the tilde means to interpret the next character (the
question mark) literally, not as a wildcard, and the question mark is the 9th character.

Related Topics
For related functions and additional information, see:

“EXACT” on page 312

“FIND” on page 312

“Specifying Conditions and Using Wildcards” on page 360

“Listing of Text Functions” on page 306

Value Types” on page 36

The Elements of Formulas” on page 15

“Using the Keyboard and Mouse to Create and Edit Formulas” on page 26

“Pasting from Examples in Help” on page 41