I want to query something with SQL\'s like query:
like
SELECT * FROM users WHERE name LIKE \'%m%\'
How to do I achieve the same in
If you are using Spring-Data Mongodb You can do this in this way:
String tagName = "m"; Query query = new Query(); query.limit(10); query.addCriteria(Criteria.where("tagName").regex(tagName));