日期:2014-05-17  浏览次数:20404 次

内容上下分页
思路:
你指定一个ID(当前的,比如是10) 
 上一页就是比10小而且是最大的。只要你去获取比10小而且是最大的。
下一页就是比10大的,而且是最小的。

求代码支持 请各位大侠帮帮忙

------解决方案--------------------
select id from table where id>当前ID limit 0,1;
select id from table where id<当前ID limit 0,1;
------解决方案--------------------
select id from table where id>当前ID order by id asc limit 1; //下一条
select id from table where id<当前ID order by id desc limit 1; //下一条

接下来就很简单了吧。