ALL(...)
All functions > ARRAY > ALL(...)
Returns TRUE if all elements in the boolean array are true.
Syntax
ALL(value, value, ...)
Notes
- NULL elements are ignored
- Returns TRUE when every non-NULL element is TRUE
- Returns FALSE when any non-NULL element is FALSE
- An empty array is TRUE. An array whose elements are all NULL is TRUE, the empty set after the NULL skip
- Known surprise: ALL(TRUE, NULL) is TRUE, while TRUE AND NULL is NULL. Quantifiers follow BOOL_AND (P8), not three-valued AND
See also
Examples
FeatureQL
RETURN
-- All true
f1 := ALL(TRUE, TRUE, TRUE),
-- Contains false
f2 := ALL(TRUE, FALSE, TRUE),
-- All false
f3 := ALL(FALSE, FALSE, FALSE)
;Result
| f1 BOOLEAN | f2 BOOLEAN | f3 BOOLEAN |
|---|---|---|
| true | false | false |