Select a specific element from nested array after update

Hello @Awakening_Quasar,

As the error said, it will not support $elemMatch in the nested property.

You can use $filter operator,

  "fields": {
    "profile.past_exams": {
      "$filter": {
        "input": "$profile.past_exams",
        "cond": {
          "$eq": [
            "$$this._id",
            new Types.ObjectId(pastExamId)
          ]
        }
      }
    }
  }