hello, i want to bucket my documents according to a change of a field
e.g : i have 3 fields : timestamp, name, switch (boolean field that i want to change bucket accordingly to it) and data :
2019-02-08T07:06:01.106Z |name1 |0
2019-02-08T08:06:01.106Z| name2 | 0
2019-02-08T09:06:01.106Z| name3| 1
2019-02-08T10:06:01.106Z| name4| 0
2019-02-08T10:06:01.106Z| name5| 0
So the results would be 3 bucket :
bucket1 having docs(name1,name2),
bucket 2 having docs(name3),
bucket 3 having docs(name4,name5)
Can this be done ?
Thanks.