您可以在猫鼬中使用 $ or 运算符返回匹配项
$ or
http://docs.mongodb.org/manual/reference/operator/query/or/的结果
Campusnotes.find({'$or':[{title:new RegExp(searchText,'i')},{description:new RegExp(searchText,'i')}]}).exec(function(err, collection) { res.send(collection);})要在数组中搜索匹配的字符串,需要使用mongo的$ in运算符:
$ in :http
:
//docs.mongodb.org/manual/reference/operator/query/in/



