db.feedback.find({
"$or":[
{"template_id":{"$regex":".*22532.*","$options":"i"}},
{"user_id":{"$regex":".*22532.*","$options":"i"}}
]
})
template_id is a string and user_id is NumberLong data type and It's not finding a result. Its giving result for template_id if I put a correct value, only user_id column seems not responding, Any thoughts?
Sample Data
{ "_id" : ObjectId("5ef21b7de21f8756b67da6e7"), "action_monkey" : 0, "feedback" : false, "more_feedback" : 0, "template_id" : "M23G5RK", "user_id" : 23423 }, /* 2 createdAt:6/15/2020, 3:16:53 PM*/ { "_id" : ObjectId("5ee74a95ae8ac276076db26a"), "action_monkey" : 0, "feedback" : false, "more_feedback" : 0, "template_id" : "M23G5RK", "user_id" : 23375 }, /* 3 createdAt:6/15/2020, 5:55:22 AM*/ { "_id" : ObjectId("5ee6c6faae8ac276076db24b"), "action_monkey" : 0, "feedback" : false, "more_feedback" : 0, "template_id" : "M23G5RK", "user_id" : 23423 }