分頁的另一種方式
分頁的另一種方式
代碼 www.2cto.com
SELECT SQL_CALC_FOUND_ROWS id,name limit 1,10;
SELECT FOUND_ROWS();
SELECT id, title, content FROM article
INNER JOIN (
SELECT id FROM article ORDER BY created DESC LIMIT 10000, 10
) AS page USING(id)