mongodb - mongoexport aggregate export to a csv file -
i want save result aggregation csv file.
using mongo cmd line tool can results want:
db.compras.aggregate({ $group : { _id : "$data.proponente", total : { $sum : "$price" } }} how translate mongoexport command saves results csv?
you can't run aggregate() queries through mongoexport. mongoexport tool intended more basic data export query filter rather full aggregation , data processing. write short script using favourite language driver mongodb, though.
Comments
Post a Comment