Locates the first occurrence of a pattern in a character string.
|source||a character string, or an expression that evaluates to a character string|
|pattern||a character string, or an expression that evaluates to a character string|
Number, being the position of the first character in source that matches the first character of pattern, when pattern is found in source.
$position returns a number that identifies the start position of pattern in source. If pattern is not found in source, $position returns 0.
If either source or pattern is not of a character data type, it is converted to a character string before the operation begins. If source is of data type ALPHA or VARALPHA, the operation is case-insensitive; otherwise, the operation is case-sensitive.
Evaluates to 4 if var1 is “defabc”.
Evaluates to 0.
find all Customers where $position(Comments, “overdrawn”) > 0
Determines if the word overdrawn appears in the Comments field for any one of your Customers.