Details
-
Bug
-
Resolution: Done
-
Blocker - P1
-
None
-
None
-
None
-
*Location*: https://docs.mongodb.com/manual/reference/operator/aggregation/range/
*User-Agent*: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36
*Referrer*: https://docs.mongodb.com/manual/reference/operator/aggregation-array/
*Screen Resolution*: 1440 x 900
*Location*: https://docs.mongodb.com/manual/reference/operator/aggregation/range/ *User-Agent*: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36 *Referrer*: https://docs.mongodb.com/manual/reference/operator/aggregation-array/ *Screen Resolution*: 1440 x 900
Description
Under the "Behaviour" section, the result for example "
{ $range: [ 0, 5 ] }" is "[ 1, 2, 3, 4, 5]".
This is not consistent with the documentation which states "$range generates the sequence from the specified starting number by successively incrementing the starting number by the specified step value up to but not including the end point."
The correct value should be "[0, 1, 2, 3, 4]".