Difference between revisions of "BETWEEN()"

From Recital Documentation Wiki
Jump to: navigation, search
(Class)
 
Line 1: Line 1:
 
 
 
==Purpose==
 
==Purpose==
 
Function to determine whether a specified expression is between two other specified expressions
 
Function to determine whether a specified expression is between two other specified expressions
Line 44: Line 42:
  
 
==Products==
 
==Products==
Recital Database Server, Recital Mirage Server, Recital Terminal Developer
+
Recital Server, Recital  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]
 
[[Category:Expressions and Type Conversion]]
 
[[Category:Expressions and Type Conversion]]
 
[[Category:Expressions and Type Conversion Functions]]
 
[[Category:Expressions and Type Conversion Functions]]

Latest revision as of 16:05, 26 November 2009

Purpose

Function to determine whether a specified expression is between two other specified expressions


Syntax

BETWEEN(<exp1>,<exp2>,<exp3>)


See Also

CHROVERLAP(), EMPTY(), EVALUATE(), EXPRCHECK(), INLIST(), INRANGE(), ISALPHA(), ISBLANK(), ISDIGIT(), MAX(), MAXVALUES(), MIN(), MINVALUES(), TYPE(), VARTYPE()


Description

The BETWEEN() function returns true (.T.) if the value of a specified expression lies in the range delimited by two other expressions all of the same data type. The BETWEEN() function operates on Character, Date and Numeric expressions.


Parameters Description
<exp1> The expression to be checked.
<exp2> Expression representing the range minimum.
<exp3> Expression representing the range maximum.


The <exp1> must be equal to or more than <exp2> and equal to or less than <exp3> for BETWEEN() to return true (.T). If <exp1> is not within this range, BETWEEN() returns false (.F.).


Example

? between(date(),date()-10,date()+10)
.T.
? between("A", "A", "Z")
.T.
? between(10,1,9)
.F.


Products

Recital Server, Recital