Open nicho2 opened 4 years ago
column name 'ts' is always required, but name can be other than 'value'
ex:
db.IndoorAirQuality_V2.aggregate ( [ { "$match" : { "SenderBuildingEntity.Sentinel": { "$in" : ["$sentinelCO2"]}, "Date": { "$gte" : "$from" } } }, {"$sort" : {"Date" : 1}},
{"$project" : { "name" : "$SenderBuildingEntity.Sentinel", "value" : "$Datas.CO2", "ts" : "$Date", "_id" : 0} } ], {"maxTimeMS":50000,"allowDiskUse":true})
column name 'ts' is always required, but name can be other than 'value'
ex:
db.IndoorAirQuality_V2.aggregate ( [ { "$match" : { "SenderBuildingEntity.Sentinel": { "$in" : ["$sentinelCO2"]}, "Date": { "$gte" : "$from" } } }, {"$sort" : {"Date" : 1}},
{"$project" : { "name" : "$SenderBuildingEntity.Sentinel", "value" : "$Datas.CO2", "ts" : "$Date", "_id" : 0} } ], {"maxTimeMS":50000,"allowDiskUse":true})