首页 话题 小组 问答 好文 用户 我的社区 域名交易 唠叨

[分享]thinksaas数据查询函数记录

发布于 2025-03-30 15:19:06
0
30
$arrTopic = aac('group')->findAll('topic',$where,'istop desc,uptime desc','topicid,ptable,pkey,pid,pjson,userid,groupid,title,gaiyao,score,label,count_comment,count_view,iscommentshow,istop,uptime',35);

第一个参数是表名

第二参数是查询条件

如:

	$where = array(
		'isrecommend'=>1,
		'isaudit'=>0
	);

第三个参数是排序

第四个参数输出表那些字段的数据

第五哥参数是 输出数量

输出固定数量可以直接写数字 也可以分页数据比如 "1,10" "11,20"

评论
一个月内的热帖推荐
站长交流