How can I find all the documents of a given array of Id's. What I wanted is something like this:
for (let y = 0; y < dadosORS_id.length; y++) {
mongoClient.collection('registosORS', function(err, collection) {
collection.find({ id: dadosORS_id[y] }).toArray(function(err, result) {
})
})
})
}
but it's not working.