rangesA range is an integer or a pair of integers. A range denotes the integers that lie between its contents. Ranges are used throughout CQL for counting things.
range := integer range := integer integerIf two integers are present, the second integer must be greater than or equal to the first integer. Examples of ranges:
10 10 20 0 1000 -1 1
Semantics of rangesIf the second argument is missing then it is taken to be equal to the first argument. A range represents the integers greater than or equal to its first argument and less than or equal to its second argument.
10denotes the number 10.
0 3denotes the four numbers 0, 1, 2, and 3.
Note on the use of ranges in the grammarMany CQL filters take what we call an optional range. This is a range that might or not be present. For example,
attacktakes an optional range: one can write either
attack (A k)or
attack 1 100 (A k), and both will be true in positions in which the black King is in check.