No, it's not a summary in the sense of map/reduce. "sum" or "max" or "count" are examples of reasonable reduce functions. Specifically, functions that are commutative, associative and reduce a variable sized input to a fixed sized output.
What you want is to find the last document matching certain criteria from a sorted list, and that doesn't need a reduce function, just the right view query. B. On Thu, Nov 11, 2010 at 10:21 PM, Mike Bannister <[email protected]> wrote: > Cory, cool thanks. Wasn't able to decide on my own if reducing was OK for > this kind of thing. > > Robert, but I need one document for each user, wouldn't that be a summary of > sorts? > > -Mike > > > On Nov 11, 2010 4:46 PM, "Cory Zue" <[email protected]> wrote: > > You could emit the users as keys, and in your reduce function just > return the latest by date. > > > On Thu, Nov 11, 2010 at 4:35 PM, Mike Bannister <[email protected]> > wrote: >> Yeah, I'm trying... >
