Skip to content

Instantly share code, notes, and snippets.

@dgadiraju
Last active February 14, 2019 04:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dgadiraju/18d6e03109b24401bcdc996f70c87e72 to your computer and use it in GitHub Desktop.
Save dgadiraju/18d6e03109b24401bcdc996f70c87e72 to your computer and use it in GitHub Desktop.
db.orders.aggregate([
{
$lookup:
{
from: "orderItems",
localField: "order_id",
foreignField: "order_item_order_id",
as: "order_item_details"
}
}
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment