输入banner图图片脚本导航/分类

Thinkphp field() 数据库查询函数使用

 

复制代码

9. field group 之后 某一个字段以“,”分割形式展示

->group(id)->field(‘group_concat(score order by `score ` desc) as score‘)复制代码

 

10. group 之后 field 里面查询最新一条里面的数据

->group(‘status‘)->field(‘SUBSTRING_INDEX(group_concat(id order by `id` desc),",",1) as id‘)复制代码

 

文章转载自 https://www.juchengvi.com/looknews/62

Thinkphp field() 数据库查询函数使用

标签:number   The   合法性   end   统计   com   sel   最新   cas