Reverse Engineer MongoDB Walkthrough
Go Up to MongoDB Support
To reverse engineer your MongoDB database, please follow the steps below.
The links built into the text are hyperlinks to other areas in this wiki that can give you further information about the text that is highlighted. Should you wish to return to these instructions, click the Back button on your browser.
- Install ER/Studio Data Architect.
- Choose File > New and select reverse-engineer from the popup window.
- Click Login.
- On the following window, choose the type of connection you would like. For MongoDB select Native Connection and choose MongoDB from the dropdown list.
- Enter your MongoDB URI or click Advanced Options to manually enter connection and authentication information. In our example we are using the server IP address (10.150.40.240) and the default admin account which we entered the username and password in the Advanced Options section.
- Click Next to connect to the MongoDB server.
- Now you have authenticated and connected to the MongoDB server, you can select, or type in the name of the database you would like to reverse engineer.
- Click Next.
- Select the tables or collections you would like to reverse engineer.
- Click Next.
- On Page 4 you can choose the desired layout. This can be changed again at a later time from within the model explorer, using the layout menu.
- Page 5 allows you to set the type of physical model, any external naming standards, and a summary of the selected objects.
- Click Finish to complete the wizard.
- ER/Studio Data Architect separates the logical data model from the physical representation for a specific DBMS. After the reverse engineering, the logical model is shown. Click on the Physical model node in the tree to see the Physical model of the reverse engineered.
- Collections are indicated by square corners. All collections have an _id field. Nested objects are indicated by rounded corners.
- Add Collections to your model by selecting the Add Collection tool and dropping them in.
- Add nested objects to your model by selecting the Add Nested Object tool and dropping them in. If you have a collection or other nested object selected before using the nested object tool, then a containment relationship will automatically be created from that selected object.
- Open the Collection Editor by double-clicking an object.
Tip: Go to diagram and object display options and check the Datatype option under Table to show the data types of your fields in the model.