json - MongoDB export to CSV the results of an aggregate unwind query? -
this question has answer here:
i'm getting 'error validating settings: query not valid json: json: cannot unmarshal string go value of type map[string]interface {}' when trying output query csv.
my query is: 'dev_experts:{$aggregate([{$unwind:"$expertise"}])}'
how "unmarshal" that? i've run query through robomongo , can see results want export, can't export them through there.
thanks in advance.
maybe should try query syntax, though i'm not robomongo expert ;)
db.dev_experts.aggregate([{$unwind:"$expertise"}]);
cf https://docs.mongodb.com/manual/reference/operator/aggregation/unwind/ more infos.
Comments
Post a Comment