Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
集合users数据量比较大,执行 db.users.distinct("name") 会报 "distinct too big, 16mb cap" 的错误,
请问这种错误怎么解决,或者有什么替代的方法来实现 distinct 能成功执行。
可以使用aggregate方式去呈現
db.users.aggregate([{$group: {_id: '$name'} }]);
慢了一步,樓上正解
与 萌阔论坛 的连接断开,我们正在尝试重连,请耐心等待