标签: java mongodb count mongotemplate
如何通过MongoTemplate这样的SQL对MongoDB中的多字段进行计数:
select count(distinct field1), count(distinct field2), count(distinct field3), sum(field4) from collectionName