.. _`MongoDB`: .. _`com.sympathyfordata.database.mongodb.connection`: MongoDB ``````` .. image:: mongodbnode.svg :width: 48 MongoDB database collection Documentation ::::::::::::: MongoDB database connection. Connection URL, database and collection can be specified either as part of the configuration or using an opt-in URL type datasource port. When using URL type datasource port, create a _Datasource_ node, set the datasource type to be URL, and add two environment variables with names "database" and "collection" under the Environment section. The standard URL connection scheme has the form: mongodb://[username:password@]host1[:port1][,...hostN[:portN]]... [/[defaultauthdb][?options]] See https://docs.mongodb.com/manual/reference/connection-string/ for more details. If the URL resource contains credential variables, these will be entered as part of the URL. See the documentation for credentials in Sympathy for Data for more info. Tied to a specific collection which can be changed using Set Collection. Definition :::::::::: Input ports ........... **connection_url** 0 - 1, datasource Connection URL. Alternative configuration using an URL type datasource with URL environment Output ports ............ **mongodb** mongodb MongoDB Configuration ............. **Collection** (collection) Collection name (required) **Connection URL** (connection_url) Connection URL **Database** (database) Database name (required) **URL** (url_connection) Uniform Resource Locator (URL) Can use the credential system for storing credentials outside of the node's configuration. For more information, see the Credentials section of the documentation. Examples ........ * :download:`MongoDBtoTable.syx ` * :download:`MongoDBBasicOperations.syx ` Implementation .............. .. automodule:: node_mongodb :noindex: .. class:: MongoDBConnection :noindex: