Create a Project By Connecting to a Live Database
On this page
You can create a project using a live database connection. Creating a project is the first step in the migration process. When creating a project with a live connection you:
Provide the connection details for your source relational system.
Provide the connection details for your destination MongoDB deployment.
Select the database, schema, and tables that are part of the migration.
About this Task
Creating a project with a live connection is the recommended process for starting a new Relational Migrator project.
Before finalizing the creation of your project, you have the choice to select the initial mappings. These options include starting with a recommended MongoDB schema, which is automatically suggested by Relational Migrator based on your relational database.
Steps
Click New Project at the top-right of the Relational Migrator home screen.
Click the Connect database button.
Select a database type. Relational Migrator supports migrating from the following database types:
MySQL
Oracle
PostgreSQL
SQL Server
Sybase ASE
DB2
Enter the connection details to create the JDBC URI for your relational database.
Enter a host IP or DNS name in the Host text box.
Enter a port number in the Port text box.
Enter a database name in the Database text field. Depending on your relational database, this behavior varies:
Database TypeBehaviorOracleThe database name is required. You also need to specify a Service ID or SID.SQL ServerThe database name is required.MySQLLeaving database name blank loads all databases.PostgresLeaving database name blank loads schemas from the default database.Sybase ASEThe database name is required.DB2The database name is required.Enter a user name in the Username text box.
Enter a password in the Password text box.
(Optional) Click the Save a password for this session check box to avoid reentering your password in the project.
Click the SSL toggle switch to enable or disable SSL and select an SSL mode.
Click Connect.
Connection and SSL details depend on the database type you are connecting to. In addition to the generic connection properties listed above, you may also need to select an
Identifier
for Oracle andAuthentication
for SQL Server.Note
If you want to specify the JDBC URI manually, click the Enter URI manually toggle switch on the Connect to the database screen. For details see, Relational Database Connection Strings.
From the Select tables screen, indicate the tables you want to migrate and click Next.
The following table explains the different ways you can select tables to migrate:
TargetActionAll tables within a databaseClick the check mark for the target database.All tables within a schemaExpand the target database and click the check mark for the target schema.Specific tables within a schemaExpand the target database and schema. Select the target tables individually.Specific table namesUse the Filter bar above the Relational Schema list.Choose a Global casing option for collection names.
This option affects the names of your collections created from the tables in your relational database:
Keep Original: Keep the original casing used in your relational database table name.
Override with Global Casing: Override the original table name with a global casing convention.
camelCase
TitleCase
kebab-case
snake_case
UPPER_SNAKE_CASE
Choose an Initial mappings option for your MongoDB schema.
- Start with a MongoDB schema that matches your relational schema
- Creates your initial project with a new document mapping rule for each table.
- Start with a recommended MongoDB schema
- Relational Migrator creates mapping rules for a suggested MongoDB schema. When you choose this option, a table appears showing the imported relational tables. Relational Migrator suggests which tables should be represented as top-level or embedded collections. You can use the checkboxes to modify which tables are mapped into collections or embedded.
- Start with an empty MongoDB schema
- Creates your initial project with no mapping rules.
Note
Regardless of the option you choose when starting your project, you have the flexibility to manually add, remove, or modify mapping rules at any time. This allows you to customize the MongoDB schema according to the specific requirements of your workload.
Enter a name for your project.
Click Done.