Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

自定义sql语句 不能实现分页

[复制链接]
dfg123456 发表于 2009-12-6 18:00:47 | 显示全部楼层 |阅读模式
进行如下查询,要求在现实的资讯文章里面同时显示带图片和不带图片的文章混合显示。如下语句已经实现,但是未能进行分页,   xxxx_multipage这个找不到对应的值

SELECT ss.*,sa.aid, sa.isavailable, sa.type, sa.catid, sa.uid, sa.dateline, sa.filename, sa.attachtype, sa.isimage, sa.size,sa. filepath, sa.thumbpath,ss.itemid FROM supe_spaceitems as ss left join supe_attachments as sa  on sa.itemid=ss.itemid  where ss.catid = 19 AND ss.folder = 1 group by ss.itemid order by ss.dateline


以下是生成后的引用代码
<!--{block name="spacenews" parameter="type/yw/sql/SELECT%20ss.%2A%2Csa.aid%2C%20sa.isavailable%2C%20sa.type%2C%20sa.catid%2C%20sa.uid%2C%20sa.dateline%2C%20sa.filename%2C%20sa.attachtype%2C%20sa.isimage%2C%20sa.size%2Csa.%20filepath%2C%20sa.thumbpath%2Css.itemid%20FROM%20supe_spaceitems%20as%20ss%20left%20join%20supe_attachments%20as%20sa%20%20on%20sa.itemid%3Dss.itemid%20%20where%20ss.catid%20%3D%2019%20AND%20ss.folder%20%3D%201%20group%20by%20ss.itemid%20order%20by%20ss.dateline/perpage/18/subjectlen/18/subjectdot/1/showdetail/1/messagelen/70/cachename/wgyw2/tpl/data"}--><!--yw-->


perpage=18,这个参数已经出现了 但是为什么填充20多条数据以后始终都是   "    当前只有一页   "这一行,模块已经被执行,可以显示数据但是只有第一篇,向高手求教
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-11-17 12:51 , Processed in 0.019974 second(s), 3 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表