I have 2 collections
Incident
{
_id:...,
suspects : [{id:...,...},{}...]
}
and Suspect
{
_id:...
}
The suspects in the Incident document are nested object that is not the equal to the document in collection Suspects but a subset with an id that matches the suspect in the suspects collection.
I would like to query the db, either for the incidents and to attach at the array (or create new one) with the actual documents that matches the ids or Query for suspects with attached a property that is the incident document where the suspect id exists in the array.