Rereduce and id


#1

According to https://docs.couchbase.com/server/6.0/learn/views/views-writing-custom-reduce.html

When rereduce is false:

  • The supplied key argument will be an array where the first argument is the
    key as emitted by the map function, and the id is the document ID that generated the key.
  • The values is an array of values where each element of the array matches the corresponding element within the array of keys.

Where is id ?? we have just key, values, rereduce arguments

function(key, values, rereduce) {
…

return retval;
}

#2

Hi @socketman2016,

I’m not exactly sure how to answer your question, but I opened up a ticket to look at updating the docs and possibly making it clearer: https://issues.couchbase.com/browse/DOC-4898