uni-app 数据库有一百多万条数据导致集合操作超时怎么办
uni-app 数据库有一百多万条数据导致集合操作超时怎么办
示例代码:
/
* let res=await db.collection("my-code").where(`uid=='665017df816a3f647e107b2a'`).limit(1000).get("_id");
console.log(res); *
/
操作步骤:
let res=await db.collection("my-code").where(`uid=='665017df816a3f647e107b2a'`).limit(1000).get("_id"); console.log(res);
预期结果:
正常返回数据
实际结果:
https://uniapp.dcloud.net.cn/uniCloud/db-performance
Error: Error in $cursor stage :: caused by :: operation exceeded time limit,集合操作超时,请参照此文档进行优化:
at chunk-vendors.js:30597:20
bug描述:
数据库有一百多万条导致集合操作超时怎么办
更多关于uni-app 数据库有一百多万条数据导致集合操作超时怎么办的实战教程也可以访问 https://www.itying.com/category-93-b0.html
1 回复
更多关于uni-app 数据库有一百多万条数据导致集合操作超时怎么办的实战教程也可以访问 https://www.itying.com/category-93-b0.html
你好,按照提示的文档地址进行优化 性能优化