get only distinct documents in mongodb using find code example Example: find distinct in mongodb db.inventory.distinct( "item.sku", { dept: "A" } )