Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有以下 SQL 代码;
SELECT * FROM myTable WHERE id = 1 LIMIT 4, 10;
我希望 sql 从结果 4 开始运行,但没有结束限制,所以我希望脚本从 4 开始获取所有结果。这可能吗?
任何帮助表示赞赏。
您可以OFFSET在查询中使用该选项。像这样
OFFSET
SELECT * FROM myTable WHERE id = 1 OFFSET 4
SELECT * FROM tbl LIMIT 4, 18446744073709551615;
资源 mysql 文档。