Mongodb – Getting the document field names and adding them as nested fields in an Aggregation
Im writing a mongodb aggregate pipeline. My documents are of the form below : { name: "01" tags { tag_01: { a: "a01-val", b: "b01-val" }, tag_02: { a: "a02-val", b: "b02-val" } } }, { name: "02" tags {…