您的位置:首页 > 编程语言 > PHP开发

TP3.2 join查询加where条件

2018-02-08 14:06 337 查看
用join的时候如果有where,需要把where的判断字段加上表名的,是带前缀的表名!

$data['tp_one.dell'] = "0";
$array['newslist'] = $News->where($data)->join('tp_two ON tp_one.catid = tp_two.id')->select();
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  tp3.2 join where