Inside Mongodb I would like to search with regex. For example I would like to make a query to returns all of these:
"ab-cd/ef"
"ab/cd.ef"
"abcdef"
I have created that query
db.getCollection('collection').find({detail:{$regex:"ab.*.cd.*.ef"}}
but the problem is that it cannot find "abcdef"