how to apply two conditions on fetching the data from single array in mongodb in express
User.findOne({'About.Phone':phone,'About.Password':password},function(err,result){
if(err){
console.log(err)
}
else{
}
})
// about is the name of array and phone,password is the sub part of the object
Comments
Post a Comment