How i can use LIKE” operator in mongoose

203

How i can use “LIKE” operator in mongoose -

// Using MongoDB Driver
var colName="v";
 models.customer.find({ "abc": { $regex: '.*' + colName + '.*' } },
   function(err,data){
         console.log('data',data);
  });

Comments

Submit
0 Comments