This tutorial walks you through the steps that are needed to create a project and a procedure in Oracle Data Integrator (ODI) to create and populate a relational table.
Approximately 30 minutes
A common task that is performed using ODI is to create and populate a relational table. This tutorial walks you through the steps that are needed to create a project and a procedure that will create and populate a relational table with data. You also execute the procedure and verify the execution within ODI Operator.
Linda works as a database administrator for Global Enterprise. In Global Enterprise, Linda is responsible for performing database management and integration tasks on the various resources within the organization. In particular, Linda is responsible for data loading, transformation, and validation. To begin working on her projects, Linda created the new Master repository and Work repository. Now Linda needs to create a project and a procedure to create a relational table and populate it with data.
The following is a list of software requirements:
Before you start the tasks, make sure that your system environment meets the following requirements:
. |
Have installed Oracle Database 11g. If not done before, start the services and components for Oracle Database 11g |
|---|---|
. |
Have installed Oracle Data Integrator 11gR1 |
. |
Before attempting this OBE, you should have successfully completed the following OBE:
To access this OBE, click HERE. |
You need to create a schema to host the RDBMS table. In this OBE, you use the RDBMS user/schema ODI_STAGE.
Note: You may skip this section if you completed one of the following OBEs:
To access these OBEs, click HERE.
To create a new RDBMS schema for the ODI datastore, perform the following steps:
. |
Start SQL Developer. You will create the new schema/user by executing the following SQL commands:
![]() ![]() |
||
|---|---|---|---|
. |
If not done before, in SQL Developer create new connection called ODI_STAGE. Enter User name as ODI_STAGE with password ODI_STAGE. For SID enter ORCL. Click Test to verify connection, and then click Connect. |
Note: You may skip this section if you completed one of the following OBEs:
After you created the new database target datastore, you need to create a new ODI target data server and the Physical schema. To create the ODI target data server and physical schema, perform the following steps:
. |
In ODI, Open ODI Topology Navigator and then select the Physical Architecture tab. Expand Technologies, right-click Oracle and select New Data Server.
|
||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
. |
In the Data Server: New window, enter the values provided in the table below. Click the JDBC tab.
|
||||||||||
. |
Click
|
||||||||||
. |
Click Test Connection. In the window that opens, click Yes to save your data. In the Information window, click OK. Click Test to verify successful connection. Click OK.
|
||||||||||
. |
Click Expand Oracle technology node, right-click ODI_STAGE dataserver, and then select New Physical Schema.
|
||||||||||
. |
In Schema (Schema) and Schema (Work Schema) field enter your ODI_STAGE schema. Click Save button. Close ODI_STAGE.ODI_STAGE physical schema window. In the Information window, click OK.
|
||||||||||
. |
Open Logical Architecture tab, expand Technologies > Oracle. Right-click Oracle technology and then select New Logical Schema.
|
||||||||||
. |
Name logical schema ODI_STAGE. In the Global context, connect this logical schema to ODI_STAGE physical schema as shown below. Click Save |
To create a new project within Oracle Data Integrator, perform the following steps:
. |
Start ODI Designer: Start > Programs > Oracle > Oracle Data Integrator > ODI Studio . Select WORKREP1 from the Login Name drop-down list if not already selected. Enter SUPERVISOR in the User field and SUNOPSIS in the Password field. Click OK to login.
|
|---|---|
. |
In the designer tab, click the Projects tab, click New Project icon
|
. |
On the screen that appears, set the Name of the project to
Procedure-CRT-TBL in the Name field. The Code field is filled automatically. Click Save icon
|
To create a new ODI procedure to create and populate RDBMS table, perform the following steps:
. |
In the Projects tab, expand: Procedure-CRT-TBL > First Folder. Right-click Procedures and select New Procedure. ![]() |
||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
. |
Enter the procedure name as PRD-create-populate-table. Set Target Technology to Oracle. Click the Details tab. Click the icon |
||||||||||
. |
In the Command: New window, enter the parameters of the procedure and the command on target provided below. You need this command to drop the table in case the table with this name exists. Select the Ignore Errors check box. Select details tab.
|
||||||||||
. |
Click the icon
|
||||||||||
. |
Click the icon
|
||||||||||
. |
View your newly created commands and click Save |
||||||||||
. |
Expand Procedure-CRT-TBL > Procedures, select the newly created procedure PRD-create-populate-table, and then select Execute. Click OK. Click OK again.
|
||||||||||
. |
Open ODI Operator. In ODI Operator, click All executions node, click the Refresh
|
||||||||||
. |
Open the Oracle SQL developer and expand ODI_STAGE connection. Select Tables node and click Refresh button
|
In this tutorial, you have learned how to:
![]()
|
About
Oracle |Oracle and Sun | |