天天看點

小程式雲開發模糊查詢

​​小程式雲開發模糊查詢​​

const db = wx.cloud.database(); //初始化資料庫
   db.collection("all").where({
      // name: _name,
      name:{
        $regex:'.*'+ 模糊比對的值,
        $options: 'i'
      }
    }).get({
 
    });