Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-2517

Allow mapReduce to create full documents

    • Type: Icon: New Feature New Feature
    • Resolution: Won't Do
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: MapReduce
    • Labels:
      None
    • Query

      This is a follow up to a support thread: http://groups.google.com/group/mongodb-user/browse_thread/thread/7e1f16c81940c24b

      Please allow mapReduce jobs to optionally return full documents instead of placing the result into the value field.

      The _id of the documents would be the reduction key, but the returned value from reduce (or finalize) would be required to be a hash. This makes working with a permanent collection generated by a map/reduce job much nicer.

      I suggest that a new out option be added:

      out:

      {document: 1}