我正在尝试使用以下查询以10K为块来选择记录:
从其中选择第一个10000*='999'
如何选择接下来的几组记录。
感谢在这方面提供的任何帮助。Informix不允许使用Limit或Fetch。
不用担心,我得到了答案:
select skip 10000 first 10000
* -- or whatever columns are needed
from table A, table B
where a.cola = b.cola
这将选择行10001到20000。
下面的查询选择行20001到30000
select skip 20000 first 10000
* -- or whatever columns are needed
from table A, table B
where a.cola=b.cola
依此类推……选择行30001-40000
select skip 30000 first 10000
* -- or whatever columns are needed
from table A, table B
where a.cola = b.cola