PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Saturday the 16th of January, 2021

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[02:11:29] <d4rkp1r4t3> micw: yeah you want a compound index. {timestamp:1, fieldX:1}.
[02:12:06] <d4rkp1r4t3> and yeah that type of workload would be fine
[15:22:33] <micw> would a compbound index of (timestamp,field1,field2,field3,field4) also work if I filter only on 2 or 3 of the fields? Or wopuld I need one for every possible combination of filtering/sorting?
[19:08:58] <dreamreal> micw: you'd have to try but you could probably create an index for every individual field and the engine SHOULD filter pretty well based on that
[19:09:11] <dreamreal> you wouldn't necessarily NEED compound indexes, although they might help
[20:07:51] <VectorX> hi, is there a tutorial video sort of thing going thru this process and how to use it, https://www.mongodb.com/blog/post/building-with-patterns-the-computed-pattern
[22:04:12] <d4rkp1r4t3> micw: yes that would work still. you will need to use the index prefix. so timestamp1,field1,field2,etc.. would work but timestamp,field2,field3 would not count as a prefix and thus not use the index.
[22:05:18] <d4rkp1r4t3> VectorX: mongodb university has a video on their data modeling course for all kinds of patterns, including the computed pattern model https://university.mongodb.com/courses/M320/about
[22:07:53] <VectorX> d4rkp1r4t3 ty, ill go thru it