mongodb 获取数组长度

db.foo.count({"type":1});
原文地址:https://www.cnblogs.com/hcy-fly/p/9584463.html