When to use this connector
MongoDB is a document database with the scalability and flexibility that you want and the querying and indexing that you need.
Working with MongoDB is similar to working with files. The MongoDB document id is a file name, and the associated with the document id document is the file content.
Etlworks Integrator can read and write data stored in MongoDB. Read how to work with MongoDB in Etlworks Integrator.
Creating a connection
Create a MongoDB connection in the Connections window by clicking the +
button, typing in mongo
, and selecting MongoDB as the connection type. You can choose between:
- MongoDB - use it if you want to store entire dataset (for example extract from Excel worksheet) as a single MongoDB documnet.
- Streaming MongoDB - use it if you want to store each record of the extracted dataset as a separate MongoDB document.
Connection parameters
- URL - the required connection string. Read about the MongoDB connection string.
- Database - the required MongoDB database name.
- Collection - the required collection name, which belongs to a specific database.
- User - optional MongoDB username.
- Password - optional MongoDB password.
- Remove Object ID when Reading - if this option is enabled, the system will remove the document ID when reading a document. It can be useful if the document is a JSON array and you just need to read the contents of the JSON array.
- Number of Documents in Explorer - the maximum number of MongoDB documents that can be displayed in Explorer. The default value is
1000
; the maximum possible value is9999
. A MongoDB can contain millions of documents, so displaying all of them might kill the server.
This parameter is used only by Explorer and has no effect when reading MongoDB documents while executing data integration flows.
- Filter - a wildcard or a JSON filter to retrieve documents from MongoDB when browsing MongoDB connection in Explorer.
This parameter is used only by Explorer and has no effect when reading MongoDB documents while executing data integration flows.
Options:
1. A fully qualified document name - the document id as it is stored in MongoDB.
2. A wildcard document name, for example, sales_orders*
. The system will read all the documents which match the wildcard.
3. A request to MongoDB in the JSON format. The system will read all the documents which match the request. An example is the request: {"first":"Simba"}
- Encoding - additional encoding which can be applied when creating a MongoDB document.
Comments
0 comments
Please sign in to leave a comment.