多条件查询,分组计数
db.user.aggregate(
{"$match":{"dia_del_flag": 0}},
{"$match":{"MessageStatus": "2"}},
{"$match":{"Batch": {"$nin":['TEST01','TEST03','SEATEST0830','SEATEST0901','SEATEST0904','SEATEST09042','SEATEST09041','TEST05','SEATEST0906','TEST20220825','TEST202208251','TEST202208261','SEATEST0912','TEST_NAF']}}},
{"$group":{"_id":"$A6_VCN_Code","total":{"$sum":1}}}
)