0

I have to request the field "type" and I can't find right syntax..enter image description here

Soswolf
  • 25
  • 1
  • 8

1 Answers1

1

Try this one:

db.collection.find({
  "conditions_object": {
    $elemMatch: {
      $elemMatch: {
        type: "PORT"
      }
    }
  }
})

MongoPlayground | Source

Valijon
  • 12,667
  • 4
  • 34
  • 67