Untitled

mail@pastecode.io avatar
unknown
plain_text
a month ago
498 B
1
Indexable
Never
db.getCollection("massive-data").aggregate([

  {
    $match: {
               friends: {$exists: true, $ne: []}
            }
  } ,
  { 
    $unwind: "$friends"
  } ,
  {
   $match: { 
             "friends.name" = /^W/ 
           }
  },
  {
    $group: {
             _id: "friends.name"
           }
 }

])


error:  clone(t={}){const r=t.loc||{};return e({loc:new Position("line"in r?r.line:this.loc.line,"column"in r?r.column:...<omitted>...)} could not be cloned.

Leave a Comment