# at, atany, rat

### at(lookForStr, searchStr)

Return the position of the first occurrence of the string in the searched string as an Integer

### atany(lookForStr, source1 ..., sourceN)

Concatenates the source strings together, then returns the position of the first occurrence of the string in the searched string/s as an Integer

### rat(lookForStr, searchStr)

Return the position of the last occurrence of the string in the searched string as an Integer

## Arguments

Argument | Data Type | Description
searchStr | string or field | string or field to search
lookForStr | string | string to search for

## Returns

Position of a character/set of characters determined by the string argument, or 0 if not found.

## Description

Returns the position of the specified section of a set of characters or field. The result is delivered as an integer. Decimal points and spaces are counted and treated as characters. The first character counts as a 1. If no character is found a 0 is returned. Only string values can be searched.

## Examples

Assume field1 holds the value "The quick brown fox"
Assume field2 holds the value "The slow black tortoise"

Example | Returns | Description
rat("o", #field1) | 18 | Looks for "o" in the first field
at("my", "hello my beauty") | 7 | Looks for "my" in "hello my beauty" and returns the start position
atany("k", #field1, #field2) | 33 | returns the first position of the specified string in the fields selected

## See Also

contains(), matches()