I am terribly sorry if this is super basic. I have spent hours googling / trying and it seems I need some help.
Given…
db.clients.find({name:"Aedan"}).pretty()
{
"_id" : ObjectId("60f0a879c1c9bb6a50854714"),
"name" : "Aedan",
"__v" : 0,
"pmx" : {
"conditions" : [
{
"name" : "",
"status" : ""
}
],
"surgeries" : [
{
"name" : "",
"date" : ""
}
]
}
}
…I can’t figure out how to push an element to the “conditions” array.
For example, I’d like to push “name”:“hypertension” + “status”:“active”. (from mongo shell)
It seems like this should be doable or maybe I am wrong. I just can’t seem to get the syntax correct. Any ideas?