Skip to main content

StrFind

This function returns a numeric value indicating the starting position within a string of the search string. For example, searching for “ad” within “Nevada” would return a value of 4.

Syntax:

STRFIND ("String", "SearchString")

where:

  • String is a character string, enclosed in double quotation marks.
  • SearchString is a character string, enclosed in double quotation marks, which is searched for inside String.

Syntax example:

CREATE VARIABLE NumTemp1 AS NUM

Variable = STRFIND ("SourceString","SearchString")

SET VARIABLE NumTemp1 = STRFIND ("StringTest","Test")

NumTemp1 will equal 7

Was this article helpful?

We're sorry to hear that.