## MongoDB Connection Wizard

This wizard appears when you select MongoDB and click OK in the New Data Source dialog, or in the Catalog Browser, right-click a data source and select Add MongoDB Connection from the shortcut menu, or right-click an existing MongoDB connection and select Edit Connection from the shortcut menu. It helps you to import MongoDB collection schemas and transform them to relational schemas for future use, and consists of the following screens:

- MongoDB Connection Information screen
- Connection Options screen
- Add Database screen
- Add Schema screen
- Add Table screen

Back

Goes back to the previous screen.

Next

Goes to the next screen.

Finish

Finishes confirming to transform MongoDB schemas to relational schemas.

Cancel

Does not retain any changes and closes this wizard.

Help

Displays the help document about this feature.

### MongoDB Connection Information screen

Specifies the necessary information to connect to the MongoDB server. See the screen.

Host

Specifies the host used to connect to the MongoDB server.

Port

Specifies the port number used to connect to the MongoDB server.

User

Specifies the user ID used to connect to the MongoDB server.

Password

Specifies the password of the user used to connect to the MongoDB server.

### Connection Options screen

Specifies conditional replica set members and options for the MongoDB connection. See the screen.

Replica Set Members

Lists all the replica set members of the MongoDB connection.

- Host
  Specifies the URI of the replica set members for the MongoDB connection.
- Port
  Specifies the port number of the members.
- Adds a new replica set member.
- Removes the selected replica set member.
- Options
  Specifies the options of the MongoDB server. The options are name=value pairs and the pairs are separated by "&". What you can specify are listed as follows.
  - slaveOk=true|false
    If true, the driver connected to a replica set will send reads to slaves/secondaries, or you can also read a slave/secondary database by adding its URI and port to the Replica Set Members box.
  - safe=true|false
    If true, the driver sends a getLastError command after every update to ensure that the update succeed.
  - w=n
    The driver adds { w : n } to the getLastError command. Implies safe=true.
  - wtimeoutMS=ms
    The driver adds { wtimeout : ms } to the getLastError command. Implies safe=true.
  - fsync=true|false
    If true, the driver adds { fsync : true } to the getLastError command. Implies safe=true.
  - journal=true|false
    If true, sync to journal. Implies safe=true.
  - connectTimeoutMS=ms
    How long a connection can take to be opened before timing out.
  - socketTimeoutMS=ms
    How long a send or receive on a socket can take before timing out.

### Add Database screen

Adds the databases you can access to the MongoDB connection. This screen will be displayed only when you have no right to access all the databases in the MongoDB data source. See the screen.

Add Database

Lists the databases you can access in the MongoDB data source.

- Database Name
  Specifies the names of the databases you can access in the MongoDB data source.
- Adds a new database you can access.
- Removes the selected database.

### Add Schema screen

Adds the collection schemas that will be transformed to relational schemas. This screen is not available when you edit an existing MongoDB connection. See the screen.

Schema

Lists the schemas in the database for you to select.

Added Schema

Lists the schemas that you have added.

Adds the selected schemas.

Removes the selected schemas from the Added Schema box.

### Add Table screen

Adds tables that are transformed from the relational schemas to the connection. This screen is not available when you edit an existing MongoDB connection. See the screen.

Tables

Lists the tables transformed from the MongoDB schemas.

Added Tables

Lists the tables that you have added from the relational schemas.

Adds the selected tables.

Removes the selected tables from the Added Tables box.

###### Related topics:

- MongoDB connections