Answer the question
In order to leave comments, you need to log in
MongoDB. How to build a query in this case?
Hello.
I recently started to comprehend mongodb, but I don’t understand how to correctly build a query in this case.
There is data of the following type.
{
"_id" : "DBtxpeHsdhHGozhq8Dr",
"connections" : [
{
"id" : "KLLbGZTu9EuM2PrRt",
"instanceId" : "uJqr6jn131Bibp4HK",
"status" : "online",
"_createdAt" : ISODate("2020-09-30T07:45:19.116+0000"),
"_updatedAt" : ISODate("2020-10-02T09:30:43.923+0000")
},
{
"id" : "zxKNGdwPDafRK7ary",
"instanceId" : "uJqr6jn131Bibp4HK",
"status" : "online",
"_createdAt" : ISODate("2020-10-02T07:59:44.381+0000"),
"_updatedAt" : ISODate("2020-10-02T09:30:43.892+0000")
},
{
"id" : "udtzoheBCF5ZsmgPi",
"instanceId" : "uJqr6jn131Bibp4HK",
"status" : "online",
"_createdAt" : ISODate("2020-10-02T07:59:44.571+0000"),
"_updatedAt" : ISODate("2020-10-02T09:30:44.362+0000")
},
{
"id" : "toPdumx8QSo5mAL46",
"instanceId" : "uJqr6jn131Bibp4HK",
"status" : "online",
"_createdAt" : ISODate("2020-10-02T07:59:44.643+0000"),
"_updatedAt" : ISODate("2020-10-02T09:30:44.504+0000")
}
]
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question