|
@@ -202,7 +202,7 @@ public class WaterMeterUnreadDeviceServiceImpl implements WaterMeterUnreadDevice
|
|
|
//operations.add(Aggregation.sort(Sort.Direction.DESC, "total"));
|
|
|
|
|
|
// 3,聚合查询所有信息
|
|
|
- Aggregation aggregation = Aggregation.newAggregation(operations);
|
|
|
+ Aggregation aggregation = Aggregation.newAggregation(operations).withOptions(Aggregation.newAggregationOptions().allowDiskUse(true).build());
|
|
|
// 4,查询结果
|
|
|
AggregationResults<StatMeterUnreadDevice> aggregationResults = mongoTemplate.aggregate(aggregation, "sc_meter_read_record", StatMeterUnreadDevice.class);
|
|
|
// 5,获取结果
|