I have an array of ids. Now I want to get all the documents corresponding to the ids inside that array from a collection. Is there any command by which I can achieve this?
I don't want to run a loop over that array and query for every element of the array.
Assume the array is
id = [1,2,3,4]
The collection is Scores, which has the field id
among other fields.
I'm looking for something like Scores.find(..)