每次要题时多加两个参数:向上翻页还是向下翻页;如果向上翻页,再传递一个当前第一条记录,如果向下翻页,再传递一个当前最后一条记录。明白了吗? 例如下翻: sql := 'select top 5 from table where id >' + lastrecord.id; 上翻时要变一下顺序: sql := 'select top 5 from table where id in(select * from table where id<' + lastrecord.id + ' desc)';
例如下翻:
sql := 'select top 5 from table where id >' + lastrecord.id;
上翻时要变一下顺序:
sql := 'select top 5 from table where id in(select * from table where id<' + lastrecord.id + ' desc)';
Email [email protected]
[email protected]
[email protected]