Вы находитесь на странице: 1из 11

10/07/12

Creating and Scheduling an ODI Scenario

Creating and Scheduling an ODI Scenario


Purpose
This tutorial walks you through the steps that are needed to create and schedule an Oracle Data Integrator (ODI) scenario.

Time to Complete
Approximately 20 minutes

Topics
This OBE tutorial covers the following topics: Overview Scenario Verifying the Prerequisites Creating a New Scenario with Oracle Data Integrator Scheduling a New Scenario with Oracle Data Integrator Verifying the Execution of the Scheduled Scenario with Oracle Data Integrator Summary

Viewing Screenshots
Place the cursor over this icon to load and view all the screenshots for this tutorial. (Caution: Because this action loads all screenshots simultaneously, the response time may be more depending on your Internet connection.) Note: Alternatively, you can place the cursor over each individual icon in the following steps to load and view only the screenshot associated with that step. The screenshots will not reflect the specific environment that you are using. They are provided to give you an idea of where to locate specific functionality in Oracle Data Integrator.

Overview
When a set of objects is complete and tested, a good practice is to create an ODI scenario for each object. After a scenario is created, it cannot be edited and the code for the object is regenerated and stored in the scenario. The created scenarios can also be scheduled for running virtually on any time interval within ODI. In this OBE, you create and schedule a scenario for the ODI procedure that was created in the OBE titled Creating an ODI Project and Procedure to Create and Populate a Relational Tab le. Back to Topic List

Scenario
Linda works as a database administrator for Global Enterprise. In Global Enterprise, Linda is responsible for performing database management and integration tasks on various resources within the organization. In particular, Linda is responsible for data loading, transformation, and validation. To begin working on her projects, she created the new Master repository and Work repository. Linda also created the project and the procedure to create a relational table and populate it with data. She set up and installed an ODI Agent as a service. Now Linda needs to create and schedule an ODI scenario to run the procedure at the appropriate time. Back to Topic List

Verifying the Prerequisites


Before you start the tasks, make sure that the following requirements are met: The system should include the following installed products: Oracle Database 10g XE Oracle Data Integrator 10g (10.1.3.4) You should have successfully completed the OBE titled Creating and Connecting to ODI Master and Work Repositories before attempting this OBE. To access this OBE, click HERE. You should have successfully completed the OBE titled Creating an ODI Procedure to Create and Populate a Relational Tab le. To access this OBE, click HERE. You should have successfully completed the OBE titled Setting Up and Installing an ODI Agent as a Background. To access this OBE, click HERE. If not done before, start the services and components for Database 10g XE and Oracle Data Integrator 10g (10.1.3.4). Back to Topic List

Creating a New Scenario with Oracle Data Integrator


To set up a new ODI Agent, perform the following steps: 1. Start ODI Designer: Start > All Programs > Oracle > Oracle Data Integrator > Designer. Select WORKREP from the Login Name dropdown list if not already selected. Enter SUPERVISOR as the User name and SUNOPSIS as the Password. Click OK to log in.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

1/11

10/07/12

Creating and Scheduling an ODI Scenario

2. In ODI Designer, click the Projects tab. On the Projects tab, expand the project: ODIcreate_table > First Folder > Procedures. Rightclick the PRGcreate-populate_table procedure and select Generate Scenario.

3. Name the scenario CREATE_AND_POP_SALES_PERSON. Set the Version to 001. Click OK.

4. Expand the PRGcreate-populate_table procedure and expand Scenarios. Right-click the CREATE_AND_POP_SALES_PERSON scenario to view the possible options as shown in the following screenshot. Note: The scenario has now been successfully created. You can now execute the scenario directly, use the scenario within a package, or schedule the package within ODI.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

2/11

10/07/12

Creating and Scheduling an ODI Scenario

Back to Topic List

Scheduling a New Scenario with Oracle Data Integrator


To schedule the scenario, perform the following steps: 1. Open the Services window (select All Programs > Administrative Tools > Services) and stop the Oracle DI Agent service if started. Close the Services window.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

3/11

10/07/12

Creating and Scheduling an ODI Scenario

2. Open (if not opened ) the Oracle XE Database Home page: Start > All Programs > Oracle Database 10g Express Edition > Go To Database Home Page. The Login screen appears. Log in to the database as user ODI_STAGE3. The password for this user is password.

3. On the Oracle Database 10g Express Edition Home screen, select SQL Commands > Enter Command from the SQL drop-down list. Enter and run the statement that is provided below. If the SRC_SALES_PERSON table exists, it is dropped. Otherwise, the message "table or view does not exist" is displayed.

d r o pt a b l eO D I _ S T A G E 3 . S R C _ S A L E S _ P E R S O N

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

4/11

10/07/12

Creating and Scheduling an ODI Scenario

4. Open the Command window and change the directory to the ODI_HOME\bin directory (for example, I:\ODI\oracledi\bin). To start ODI Agent as a scheduler, execute the agentservice.bat file by using the following command:

a g e n t s c h e d u l e r . b a t N A M E = l o c a l a g e n t

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

5/11

10/07/12

Creating and Scheduling an ODI Scenario

Note: To perform this step, an ODI Agent must be set up. To set up an ODI Agent, see the OBE titled Setting Up and Installing an ODI Agent as a Background. To access this OBE, click HERE.

5. Expand the PRGcreate-populate_table procedure. Expand Scenarios > CREATE_AND_POP_SALES_PERSON. Right-click Scheduling, and then select Insert Scheduling.

Note: If an ODI Agent is not set up within the ODI Topology Manager, the following error message appears: "To use the scheduling, please set an agent in your repository." To schedule a scenario, an Agent must be set up. To set up an ODI Agent, see the OBE titled Setting Up and Installing an ODI Agent as a Background. To access this OBE, click HERE.

6. On the screen that follows, select the agent where the scheduled scenario will run: localagent. Set Context as Global and log level to 5. Set Execution to Simple and click the the execution time to approximately 5 minutes from the current system time as shown in the following screenshot. Click OK. Click OK again. button. Set

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

6/11

10/07/12

Creating and Scheduling an ODI Scenario

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

7/11

10/07/12

Creating and Scheduling an ODI Scenario

7. Expand Scheduling and verify that the localagent entry is now inserted under Scheduling.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

8/11

10/07/12

Creating and Scheduling an ODI Scenario

8.

Click the icon to start Topology Manager to review the scheduling of the Agent. Expand the Agents node, right-click localagent, and select Edit. On the Agent: localagent screen, click Update Scheduling. On the screen that follows, click OK.

9. Click the Scheduling information button. The screen that appears shows you the scheduling information.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

9/11

10/07/12

Creating and Scheduling an ODI Scenario

Back to Topic List

Verifying the Execution of the Scheduled Scenario with Oracle Data Integrator
To verify the execution of the scheduled scenario, perform the following steps: 1. To verify that your scheduled scenario was executed successfully, you need to open ODI Operator. Click the ODI Operator icon on the menu bar to start ODI Operator. In ODI Operator, click the Session List tab

. Expand Date > Today > CREATE_AND_POP_SALES_PERSON, and view the execution results for the PRG_create-populate_table procedure.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

10/11

10/07/12
2.

Creating and Scheduling an ODI Scenario


Expand Physical Agent > localagent > CREATE_AND_POP_SALES_PERSON, and view the execution results for the PRG_create-populate_table procedure. Note the execution time of this scenario, that is, the time that you scheduled with ODI Agent. You have now successfully scheduled a scenario with an agent scheduler. The scenario was executed by the agent successfully.

Note: If you want to execute the procedure again, you must first drop the SRC_SALES_PERSON table as described in step 2 of the "Scheduling a New Scenario with Oracle Data Integrator" section. Back to Topic List

Summary
In this tutorial, you learned how to: Verify the Prerequisites Create an ODI Scenario with Oracle Data Integrator Schedule an ODI Scenario with Oracle Data Integrator Verify the Execution of the Scheduled ODI Scenario with Oracle Data Integrator

Back to Topic List

Place the cursor over this icon to hide all screenshots.

oracle.com/webfolder/technetwork/tutorials/obe/fmw/odi/10g//creating_scheduling_scenario.htm

11/11

Вам также может понравиться