between, like, in Operators

between Operator

               value between bottom and top
The between operator performs a range check on a value. The sample above checks that the value of value is between the values bottom and top. It is strictly equivalent to:
               value >= bottom and value <= top
between returns a bool value.

Example (Test for alphabetic character):

  lower(char) between 'a' and 'z'

like Operator

               str like pattern
The like operator performs a SQL-style pattern match. The sample above uses pattern as a string pattern to match against str.

In the pattern string, percent (%) and underscore (_) are used as wildcards. Underscore (_) matches any single character. Percent (%) matches 0 or more characters. A back slash (\) is used to escape percent (%), underscore (_) and back slash (\). All other characters in the pattern string must match their equivalent characters in the value being matched.

like returns a bool value.

Example (Test for ampersand in string):

  str like '%&%'

in Operator

               value in arr
The in matches a value against the elements of an array. The sample above tests each element of arr against value. in returns true if there is any matching element. The second operand can be any assignment expression including a brace enclosed list.

in returns a bool value.

Examples:

  value in { 'On', 'Off' }
  code in { 1, 4, 9 }

[Return to Previous Page] [Return to Main Page]
Jive(tm) 2, Copyright © 1997 FFE Software All Rights Reserved WorldWide