If I have a document like:
{title: "hello",
formats:{mp4: {status: "processing"},
webm: {status: "processing" }} }
How can I write a $set query to set both inner status to “completed”
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I’d rework your schema to be something like:
That way you aren’t forcing a particular label and have a more abstract schema. You would have to still touch each of the status, there isn’t an update all for them.