提交 20229e06 编写于 作者: 雪洛's avatar 雪洛

docs: uniCloud database skip

上级 eedaea9c
......@@ -389,7 +389,7 @@ collection.skip(value)
let res = await collection.skip(4).get()
```
**注意:数据量很大的情况下,skip性能会很差,尽量使用其他方式替代**
**注意:数据量很大的情况下,skip性能会很差,尽量使用其他方式替代,参考:[skip性能优化](uniCloud/db-performance.md?id=skip)**
### 对结果排序
......
......@@ -18,11 +18,11 @@
对于非常大的数据可以分段来查询,即通过一定的条件将一次查询拆分为多次查询操作。
### 带条件的count
### 带条件的count@count
如果满足条件的数据特别多,where+count会特别慢,很有可能超时。我们建议不要在大数据量的集合内这样使用count方法。
### 使用skip方法传入较大的值
### 使用skip方法传入较大的值@skip
您应该避免使用where+skip+limit的查询方式来遍历整个集合,因为这种方式随着Skip数量的增长响应时间会越来越慢,还可能会造成请求超时。
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册