1
chairo 2013 年 1 月 15 日 MSSQL版本:SELECT TOP 5 * FROM table ORDER BY id, weight
MySQL版本:SELECT * FROM table ORDER BY id, weight LIMIT 5 |
3
aisk 2013 年 1 月 15 日
select * from xxx where id in (select id from xxx order by id limit 20) order by weight order by weight limit 1 offset 5;
|
4
Air_Mu OP 我想了下难道需要先查出行数 x 然后where id>(x-20) order by weight?
|
5
napoleonu 2013 年 2 月 8 日
select * from (select * from tb order by id limit 20) t1 order by weight limit 5;
|