扫码关注官方订阅号
documents = collection.find_all()for document in documents:
# 解析document的函数
数据量300万到后面越来越慢请问如何批量取数据
手机码字,敬请见谅
业精于勤,荒于嬉;行成于思,毁于随。
不太确定文件是什么样子的,给出一个普通的解法
with open(filename,'r') as documents: for document in documents: print document
如果你的文档数目非常大的话,可以采用多进程(multiprocsssing)并行处理。
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
扫描下载App
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
不太确定文件是什么样子的,给出一个普通的解法
如果你的文档数目非常大的话,可以采用多进程(multiprocsssing)并行处理。