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

Add $lookup.excludeLocalField to exclude local field from output

    • Type: Icon: New Feature New Feature
    • Resolution: Unresolved
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Aggregation Framework
    • Query Optimization

      { $lookup: {
             from: <collection to join>,
             localField: <field from the input documents>,
             excludeLocalField: <boolean>
             foreignField: <field from the documents of the "from" collection>,
             as: <output array field>
      } }
      

      If excludeLocalField = true then localField is removed from output
      IMHO: excludeLocalField must be default to true (excludedd by default)

            Assignee:
            backlog-query-optimization [DO NOT USE] Backlog - Query Optimization
            Reporter:
            joseaio Jose Antonio Illescas Olmo
            Votes:
            0 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated: