title: Using mongodb in store
body: <p>I am using mongodb for store, I need to find how frequency one item is selling. I know logic, but not syntactic way in mongo, assume I have 3 items, first itemA was sold in "2015-08-25 00:28:41", itemB "2015-08-25 00:29:05", itemC "2015-08-25 00:30:02", so I need to subtract C-B, B-A then add and divide 2. How can I do query for multiple items ? for example 100 items. Thanks.</p>