The FIND function searches a source string for a provided sub-string and, depending on the context of the function call, returns one of the sub-string, the position of its first character within the source string, or an indicator as to whether or not it was located. This search can optionally be case-insensitive and may begin at the beginning of the source string or at some character position within the source string.
Note that this function no longer works with object collection properties. This functionality is now provided by the new rule function COLLECTION_FIND. Upgrades of projects from previous platform versions will be modified with the replacement of FIND with COLLECTION_FIND in any rule definition. This will happen as a part of the standard upgrade process built into the Agentry Editor and should require no additional actions on the part of the developer.
When FIND is called in a string context, the function will search a source string for a sub-string, returning that sub-string when found or an empty string if not found.
When FIND is called in an integral number context, the function will search a source string for a sub-string, returning the position of the first character of the sub-string within the source string when found, or -1 if not found. The first character of the string is at position 0.
When FIND is called in a Boolean context, the function will search a source string for a sub-string, returning true when found and false when not found.