Use of Select(find) IN Operator in MongoDB
Following example show how to use IN operator of SQL RDBMS query in MongoDB with find function.
In this example we are looking the complete details of employees having name RAM, SHAM & SUNNY.
-- In SQL of RDBMS databases
SELECT * FROM dbo.employees WHERE name IN ("RAM","SHAM","SUNNY")
-- In MongoDB
db.employees.find( { "name":{ $in: ["RAM","SHAM","SUNNY"] } } )