Join us Sept 17 at .local NYC! Use code WEB50 to save 50% on tickets. Learn more >
MongoDB Jokes
Docs Menu
Docs Home
/ / /

Export Pipeline to Specific Language

You can use the Aggregation Pipeline Builder to format and export finished pipelines. You can export pipelines to a chosen language to use in your application.

You can export your pipeline to the following languages:

  • C#

  • Go

  • Java

  • Node

  • PHP

  • Python

  • Ruby

  • Rust

1
  1. If it's not already displayed, select the organization that contains your project from the Organizations menu in the navigation bar.

  2. If it's not already displayed, select your project from the Projects menu in the navigation bar.

  3. In the sidebar, click Data Explorer under the Database heading.

    The Data Explorer displays.

Note

You can also go to the Clusters page, and click Data Explorer under the Shortcuts heading.

2
  1. Select the collection.

  2. In the aggregation pipeline pane, click the Export to Language button to open the pipeline export card.

Aggregation Builder export button
click to enlarge
4

Click the Include Import Statements checkbox to include the required import statements for the selected programming language.

5

Click the Include Driver Syntax checkbox to include application code for the selected programming language. If you include driver syntax, the copyable code reflects project, sort, maxtimems, collation, skip and limit options.

6

Click the icon at the top-right of the pipeline to copy your pipeline for the selected programming language. You can now integrate and execute your created pipeline in your application.

Back

View Explain Plans