Copying data definitions into a project

You can copy a data definition from the Database Explorer view into a project in the Data Definition view. After you copy the data definition, you can then view the design and run queries on the database.

You can copy from the Database Explorer view to the Data Definition view by using one of the following methods:

 

Parent topic

Defining database objects

 

Related tasks

Copying or moving data objects

Copying data definitions by using the Copy to Project wizard

To copy the design of an existing database by using the Copy to Project wizard:

  1. Connect to the database.

  2. Expand the connection to show the data definitions in the DB Servers view.

  3. Select the data definitions that you want to copy.

  4. From the pop-up menu of the data definitions (database, schema, or table), click Copy to Project to open the Import window.

  5. Select the target for the copy. If the project or folder that you specify does not exist, it will be created. You must copy into the appropriate level. Databases can be copied into folders, schemas can be copied into databases, and tables can be copied into schemas. You cannot copy across database types. For example, you cannot copy a table from an Oracle database into a local DB2 database design.

  6. Click Finish.

Now you can switch to the Data Definition view to work with the imported design.

Copying data definitions by dragging and dropping

To copy data definitions by dragging and dropping:

  1. Connect to the database.

  2. Expand the connection to show the data definitions in the Database Explorer view.

  3. Select the data definitions that you want to copy.

  4. Drag and drop the data definitions to an appropriate node in the Data Definition view.