2022-03-09 16:32:01 +01:00
{
"name": "BETWEEN",
"type": "operator",
"groups": ["Operators"],
2022-06-27 13:08:00 +02:00
"description": "Returns TRUE if value is within the specified range. The range is considered inclusive of the bounds. To test for exclusion NOT BETWEEN can be used.",
2022-03-09 16:32:01 +01:00
"arguments": [{
2022-09-25 23:39:00 +02:00
"arg": "value",
"description": "the value to compare with a range. It can be a string, a number or a date."
}, {
2022-03-09 16:32:01 +01:00
"arg": "lower_bound AND higher_bound",
"description": "range bounds"
}],
"examples": [{
"expression": "'B' BETWEEN 'A' AND 'C'",
2022-03-15 12:06:13 +01:00
"returns": "TRUE"
2022-03-09 16:32:01 +01:00
}, {
2022-03-14 13:45:49 +01:00
"expression": "2 BETWEEN 1 AND 3",
2022-03-15 12:06:13 +01:00
"returns": "TRUE"
2022-06-27 13:08:00 +02:00
}, {
"expression": "2 BETWEEN 2 AND 3",
"returns": "TRUE"
}, {
"expression": "'B' BETWEEN 'a' AND 'c'",
"returns": "FALSE"
}, {
"expression": "lower('B') BETWEEN 'a' AND 'b'",
"returns": "TRUE"
2022-03-09 16:32:01 +01:00
}],
2022-09-25 23:39:00 +02:00
"notes": "<i>value BETWEEN lower_bound AND higher_bound</i> is the same as \"<i>value >= lower_bound AND value <= higher_bound</i>\".",
2022-06-27 13:14:43 +02:00
"tags": ["bound", "contained", "found", "include", "range", "within"]
2022-03-09 16:32:01 +01:00
}