mongoose array contain code example
Example 1: mongodb array field contains
db.inventory.find( { tags: { $all: ["red", "blank"] } } )
Example 2: mongoose query using an arry
var query = PUser.find({'userID': {$in:array}});
db.inventory.find( { tags: { $all: ["red", "blank"] } } )
var query = PUser.find({'userID': {$in:array}});