tp5 查询条件总结

对比下表的用法

$map['字段1']  = array('表达式','查询条件1');
$map['字段2']  = array('表达式','查询条件2');
Db->table('tableName')->where($map)->select(); // 
$map['id']='2';
$map['id']=['neq','2'];
$map['name']=['like','%'.$name.'%'];
$map['id']=['in',$ids];
$where['keywork|uname']=['like','%'.$keywork.'%'];
$where['city|county']=$cid;

 

 

posted on 2018-11-02 15:24  泽一年  阅读(557)  评论(0编辑  收藏  举报

导航