$unwind: One Document per Array Item

$unwind turns a document with an array into one document per item, so a pipeline can count, group and total the items themselves, such as the units of each product sold across every order.

By

Updated

Cheat sheet: $unwind: One Document per Array Item
Category
MongoDB
Level
Journeyman
Tags
$group, $unwind, Aggregation Pipeline, mongodb