tp5 page分页和group 一起使用出现分页错误.

浏览:1880 发布日期:2018/11/20 分类:求助交流 关键字: 分页,tp5,group
以下是我的查询代码:
$buildSql=Db::name('scenepartner')->alias('s')
- >field('s.*,sum(a.totalamount),sum(a.dividedamount)')
->join('pt_accounts a', 's.id = a.jqid')
->group('a.jqid')
->where($map)->buildSql();

$lists =Db::table([$buildSql=>'s'])
->page($Nowpage, $limits)
->order('s.id asc')->select();
最佳答案
评论( 相关
后面还有条评论,点击查看>>