Arangodb 有一个用于简单查询的 LIMIT 和 SKIP 函数,如何使用 /api/cursor 实现
FOR product in products
LIMIT 2
return product
Run Code Online (Sandbox Code Playgroud)
理想情况下是这样的
FOR product in products
LIMIT 20 SKIP 10
return product
Run Code Online (Sandbox Code Playgroud)
或者它只支持使用/_api/simple/all调用
我想我已经明白了,LIMIT 子句有一个偏移量、计数,可以用来跳过和实现分页。
LIMIT @offset, @count
FOR product in products
LIMIT 2, 10
return product
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1964 次 |
| 最近记录: |