Difference between revisions of "INLIST()"

From Lianjapedia
Jump to: navigation, search
m (Text replace - "Recital" to "Lianja")
Line 1: Line 1:
 
==Purpose==
 
==Purpose==
 
Function to search a list of expressions
 
Function to search a list of expressions
 
  
 
==Syntax==
 
==Syntax==
 
INLIST(<exp1>,<exp2>[,<exp3>...])
 
INLIST(<exp1>,<exp2>[,<exp3>...])
 
  
 
==See Also==
 
==See Also==
 
[[AT()]], [[ATNEXT()]], [[LEFT()]], [[LIKE()]], [[LOOKUP()]], [[OCCURS()]], [[RAT()]], [[RIGHT()]], [[RLOOKUP()]], [[STR()]], [[STREXTRACT()]], [[STRTRAN()]], [[STUFF()]], [[SUBSTR()]]
 
[[AT()]], [[ATNEXT()]], [[LEFT()]], [[LIKE()]], [[LOOKUP()]], [[OCCURS()]], [[RAT()]], [[RIGHT()]], [[RLOOKUP()]], [[STR()]], [[STREXTRACT()]], [[STRTRAN()]], [[STUFF()]], [[SUBSTR()]]
 
  
 
==Description==
 
==Description==
 
The INLIST() function searches a list of expressions and returns a logical true (.T) if the specified expression is found within that list.  The expression to search for is represented by <exp1>.  Expressions following <exp1> make up the list in which the INLIST() function will search.  All the expressions specified must be the same data type: character, numeric, logical, date.
 
The INLIST() function searches a list of expressions and returns a logical true (.T) if the specified expression is found within that list.  The expression to search for is represented by <exp1>.  Expressions following <exp1> make up the list in which the INLIST() function will search.  All the expressions specified must be the same data type: character, numeric, logical, date.
 
  
 
==Example==
 
==Example==
Line 24: Line 20:
 
endcase
 
endcase
 
</code>
 
</code>
 
  
 
==Products==
 
==Products==

Revision as of 12:47, 11 December 2012

Purpose

Function to search a list of expressions

Syntax

INLIST(<exp1>,<exp2>[,<exp3>...])

See Also

AT(), ATNEXT(), LEFT(), LIKE(), LOOKUP(), OCCURS(), RAT(), RIGHT(), RLOOKUP(), STR(), STREXTRACT(), STRTRAN(), STUFF(), SUBSTR()

Description

The INLIST() function searches a list of expressions and returns a logical true (.T) if the specified expression is found within that list. The expression to search for is represented by <exp1>. Expressions following <exp1> make up the list in which the INLIST() function will search. All the expressions specified must be the same data type: character, numeric, logical, date.

Example

do case
case inlist(cState, "CA", "OR", "WA", "NV")
    cTimezone = "Pacific"
case inlist(cState, "MT", "ID", "WY", "UT", "CO","AZ", "NM")
    cTimezone = "Mountain"
endcase

Products

Lianja Server, Lianja