ODI 11G hand book

Embed Size (px)

DESCRIPTION

ODI 11G hand book

Citation preview

  • 5/20/2018 ODI 11G hand book

    1/262

    Oracle Data Integrator 11g:

    Integration and Administration

    Act ivity Guide - Volume I

    D64974GC20

    Edition 2.0

    September 2012

    D78956

  • 5/20/2018 ODI 11G hand book

    2/262

    Copyrigh t 2012,Oracle and/or its affili ates. All rights reserved.

    Disclaimer

    This document contains proprietary information and is protected by copyright and

    other intellectual property laws. You may copy and print this document solely for your

    own use in an Oracle training course. The document may not be modified or altered

    in any way. Except where your use constitutes "fair use" under copyright law, you

    may not use, share, download, upload, copy, print, display, perform, reproduce,

    publish, license, post, transmit, or distribute this document in whole or in part without

    the express authorization of Oracle.

    The information contained in this document is subject to change without notice. If you

    find any problems in the document, please report them in writing to: Oracle University,

    500 Oracle Parkway, Redwood Shores, California 94065 USA. This document is not

    warranted to be error-free.

    Restricted Rights Notice

    If this documentation is delivered to the United States Government or anyone using

    the documentation on behalf of the United States Government, the following notice is

    applicable:

    U.S. GOVERNMENT RIGHTS

    The U.S. Governments rights to use, modify, reproduce, release, perform, display, or

    disclose these training materials are restricted by the terms of the applicable Oracle

    license agreement and/or the applicable U.S. Government contract.

    Trademark Notice

    Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names

    may be trademarks of their respective owners.

    uthor

    Richard Green

    Technical Contr ibutors

    and Reviewers

    Alex Kotopoulis

    Denis GrayChristophe Dupupet

    Julien Testut

    David Allan

    Sachin Thatte

    Viktor Tchemodanov

    Gerry Jurrens

    Veerabhadra Putrevu

    Editors

    Rashmi RajagopalVijayalakshmi Narasimhan

    Aju Kumar Kumar

    Graphic Designers

    Satish Bettegowda

    Seema Bopaiah

    Publishers

    Giri Venugopal

    Sumesh Koshy

    Srividya Rameshkumar

  • 5/20/2018 ODI 11G hand book

    3/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Oracle Data Integrator 11g: Integration and Administration Table of Contents

    i

    Table of Contents

    Practices for Lesson 1: Introduction to Integration and Administration ................................................. 1-1

    Practices for Lesson 1: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 1-2

    Practice 1-1: Starting the ODI Client ........................................................................................................ 1-3

    Practices for Lesson 2: Administering ODI Repositories ..................... ............. ............. ............ ............. 2-1

    Practices for Lesson 2: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 2-2

    Practices for Lesson 2: Flow of Data ............. ............. ............. .............. ............. ............. .............. ........... 2-3

    Practice 2-1: Creating and Connecting to ODI Master and Work Repositories ............ ............ ............. ...... 2-4

    Practices for Lesson 3: ODI Topology Concepts ............ ............. ............. ............. ............. ............. ........ 3-1

    Practices for Lesson 3: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 3-2

    Practice 3-1: Setting Up and Installing an ODI Agent ............ ............. ............. ............. ............. ............. ... 3-3

    Practices for Lesson 4: Describing the Physical and Logical Architecture ............................................ 4-1

    Practices for Lesson 4: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 4-2

    Practice 4-1: Working with Topology ........................................................................................................ 4-3

    Practices for Lesson 5: Setting Up a New ODI Project ................ ............. ............. ............. ............. ........ 5-1

    Practices for Lesson 5: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 5-2

    Practice 5-1: Setting Up a New ODI Project ............................................................................................. 5-3

    Practices for Lesson 6: Oracle Data Integrator Model Concepts ............ ............. ............. ............. .......... 6-1

    Practices for Lesson 6: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 6-2

    Practice 6-1: Creating a Model ................................................................................................................ 6-3

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores ....................................... 7-1

    Practices for Lesson 7: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 7-2

    Practice 7-1: Checking Data Quality in the Model ............. ............. ............. ............ ............. ............. ........ 7-3

    Practices for Lesson 8: ODI Interface Concepts ............. ............. ............. ............. ............. ............. ........ 8-1

    Practices for Lesson 8: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 8-2

    Practice 8-1: Creating ODI Interface: Simple Transformations ................. ............. ............. ............. .......... 8-3

    Practices for Lesson 9: Designing Interfaces ....................... ............. ............. ............. ............. ............. .. 9-1

    Practices for Lesson 9: Overview ............ ............. ............. ............. ............ ............. ............. ............. ....... 9-2

    Practice 9-1: Creating ODI Interface: Complex Transformations ............ ............. ............. ............. ............ 9-3

    Practice 9-2: Creating ODI Interface: Implementing Lookup ............ ............. ............. ............. ............. ...... 9-22

    Practices for Lesson 10: Interfaces: Monitoring and Debugging .................... ............. ............ ............. .. 10-1

    Practices for Lesson 10: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 10-2

    Practice 10-1: Creating ODI Interface: Exporting a Flat File to a Relational Table ............ ............ ............. . 10-3

    Practices for Lesson 11: Designing Interfaces: Advanced Topics 1 ............. ............. ............ ............. .... 11-1

    Practices for Lesson 11: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 11-2

    Practice 11-1: Using Native Sequences with ODI Interface ............. ............. ............. ............. ............. ...... 11-3

    Practice 11-2: Using Temporary Indexes ................................................................................................. 11-18

    Practice 11-3: Using Data Sets with ODI Interface ............. ............. ............. .............. ............. ............. ..... 11-28

    Practices for Lesson 12: Designing Interfaces: Advanced Topics 2 ............. ............. ............ ............. .... 12-1

    Practices for Lesson 12: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 12-2

    Practice 12-1: Using Temporary ODI Interfaces .................. ............. ............. ............. ............ ............... ... 12-3

    Practice 12-2: Developing a New Knowledge Module ............ ............. ............. ............. ............. ............. .. 12-38

    Practices for Lesson 13: Using ODI Procedures ............. ............. ............. ............. ............. ............. ........ 13-1

    Practices for Lesson 13: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 13-2

    Practice 13-1: Creating an ODI Procedure ............. ............. ............. ............. ............. ............. .............. ... 13-3

  • 5/20/2018 ODI 11G hand book

    4/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Oracle Data Integrator 11g: Integration and Administration Table of Contents

    ii

    Practices for Lesson 14: Using ODI Packages ........... ............. ............. ............. ............. ............. ............. 14-1

    Practices for Lesson 14: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 14-2

    Practice 14-1: Creating an ODI Package ............ ............ ............. ............. ............. ............. ............. ......... 14-3

    Practice 14-2: Using ODI Package with Variables and User Functions ............ ............. ............. ............. ... 14-14

    Practices for Lesson 15: Managing ODI Scenarios ............. ............. ............. ............. ............. ............. .... 15-1

    Practices for Lesson 15: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 15-2

    Practice 15-1: Creating and Scheduling an ODI Scenario ............ ............. ............. ............ ............. .......... 15-3

    Practices for Lesson 16: Using Load Plans ............. ............. ............. ............. ............. ............. ............. .. 16-1

    Practices for Lesson 16: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 16-2

    Practice 16-1: Using Load Plans .............................................................................................................. 16-3

    Practices for Lesson 17: Managing ODI Versions ............. ............. ............. ............. ............. ............. ...... 17-1

    Practices for Lesson 17: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 17-2

    Practice 17-1: Working with ODI Versions ............ ............. ............. ............. ............. .............. ............. ..... 17-3

    Practices for Lesson 18: Enforcing Data Quality with ODI ............ ............. ............. ............. ............. ...... 18-1

    Practices for Lesson 18: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 18-2

    Practice 18-1: Enforcing Data Quality with ODI Interface ........... .............. ............. ............. ............. .......... 18-3

    Practices for Lesson 19: Working with Changed Data Capture ............ ............. ............. ............. ............ 19-1

    Practices for Lesson 19: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 19-2

    Practice 19-1: Implementing Changed Data Capture ............. ............. ............. ............. ............. ............. .. 19-3

    Practices for Lesson 20: Advanced ODI Administration ............ ............. ............. ............. ............. .......... 20-1

    Practices for Lesson 20: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 20-2

    Practice 20-1: Setting Up ODI Security .................................................................................................... 20-3

    Practice 20-2: Integration with Enterprise Manager and Using ODI Console ............ ............. ............. ........ 20-22

    Practices for Lesson 21: Extending Oracle Data Integrator with SDK, Web Services, and SOA ............ 21-1

    Practices for Lesson 21: Overview ............ ............ ............. ............. ............. ............. ............. ............... ... 21-2

    Practice 21-1: Executing an ODI Scenario Through the ODI Public Web Service....................... ............. ... 21-3

  • 5/20/2018 ODI 11G hand book

    5/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 1

    Practices for Lesson 1:Introduction to Integrationand Administration

    Chapter 1

  • 5/20/2018 ODI 11G hand book

    6/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 2

    Practices for Lesson 1: Overview

    Practices Overview

    In this practice, you will start up the ODI client, and examine the help system and Start Page.

  • 5/20/2018 ODI 11G hand book

    7/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 3

    Practice 1-1: Starting the ODI Client

    Overview

    In this practice, you start up the ODI client, explore the help system, and examine the links onthe Start Page.

    AssumptionsNone

    Tasks

    1. Start Oracle Data Integrator and explore the help system:

    Step Screen/Page Description Choices or Values

    a. MS Windows Start Oracle Data Integrator: Start>Programs> Oracle > Oracle DataIntegrator > ODI Studio.

    b. Oracle Data Integrator The ODI client window opens. From the main

    menu, select Help > Table of Contents.c. Oracle Data Integrator The Help Center appears. Expand the

    navigation tree of the Contents tab. Double-click Opening the Online Help. Observe thatanother panel opens to the right, with detailsabout your chosen topic. Close the HelpCenter.

    d. Oracle Data Integrator From the Help menu, select ODI Forum.

    e. Oracle Data Integrator If you have an Internet connection, the OracleODI Forum web page opens. Scroll throughthe list of topics. Close the browser.

    f. Oracle Data Integrator On the Help menu, note that there is also alink to the Oracle Technology Network.

  • 5/20/2018 ODI 11G hand book

    8/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 4

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    9/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 5

    c.

    d.

  • 5/20/2018 ODI 11G hand book

    10/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 6

    e.

    f.

  • 5/20/2018 ODI 11G hand book

    11/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 7

    2. Examine the links on the Start Page:

    Step Screen/Page Description Choices or Values

    a. Oracle Data Integrator On the Start Page, click Define theTopology.

    b. Oracle Data Integrator On the Define the Topology tab, examine thefive different categories of information.

    Click Create and Connect to yourRepositories.

    c. Oracle Data Integrator The Help Center opens with two tabs on theright side of the ODI client.

    On the Contentstab, expand the navigation

    tree to see the help topics.

    On the tab to the right of the Contents tab,notice the detailed links for help on the topicof creating and connecting to yourrepositories.

    d. Oracle Data Integrator Click Xto close the Help Center window.

    Click Xto close the Define the Topology tab,which also closes the Start Page. If you wantto re-open the Start Page later, you canselect Start Pagefrom the Help menu.

  • 5/20/2018 ODI 11G hand book

    12/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 8

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    13/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 9

    c.

    d.

  • 5/20/2018 ODI 11G hand book

    14/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 1: Introduction to Integration and Administration

    Chapter 1 - Page 10

  • 5/20/2018 ODI 11G hand book

    15/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 1

    Practices for Lesson 2:Administering ODIRepositories

    Chapter 2

  • 5/20/2018 ODI 11G hand book

    16/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 2

    Practices for Lesson 2: Overview

    Practices Overview

    In this practice, you will use SQL Developer to create database users for Master and WorkRepositories. You will then log in to ODI and connect to these repositories.

  • 5/20/2018 ODI 11G hand book

    17/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 3

    Practices for Lesson 2: Flow of Data

  • 5/20/2018 ODI 11G hand book

    18/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 4

    Practice 2-1: Creating and Connecting to ODI Master and WorkRepositories

    Use Case Scenario:

    John works as a database administrator for FN Enterprise. In FN Enterprise, John is responsiblefor performing database management and integration tasks on various resources within the

    organization. In particular, John is responsible for data loading, transformation, and validation.To set his ODI environment, he needs to set up security and create Master and WorkRepositories.

    Background:

    To set up Oracle Data Integrator, first create database users for the Master and WorkRepositories. Then, create the Master Repository, connect to the Master Repository, create theWork Repository, and then connect to the Work repository.

    In this practice, you first use SQL Developer to create the database users for the Master andWork Repositories. Then, in ODI, you create and connect to the ODI Master Repository and theODI Work Repository.

    Note:These are practice repositories. In later lessons, you use other Master and WorkRepositories that are partially predefined with source and target objects.

    SQL Develo er

    Create SNPM1 database user forMasterRepository

    Create SNPW1 database user for

    WorkRepository

    database-play.png

    Oracle DataIntegrator

    Create Master Repository Create Master Repository connection

    Master Repository Pr 2-1 with SNPM1as the user

    Create WorkRepository Create WORKREP_PR2-1Work

    Repository connection with SNPW1 asthe user

    datab024.gif

  • 5/20/2018 ODI 11G hand book

    19/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 5

    Your Tasks:

    1. The RDBMS used in this practice is Oracle 11g. To connect to your RDBMS, perform thefollowing steps:

    Step Screen/Page Description Choices or Values

    a. MS Windows Start Oracle SQL Developer by selectingStart> Programs>Oracle-OraDb11g_home1 > ApplicationDevelopment> SQL Developer. When SQLDeveloper starts, close the Messages Logtab at the bottom. Also close the Start Page.

    b. Oracle SQL Developer In Oracle SQL Developer, click + to expandthe connection Administrator. In the windowthat follows, enter systemin the Username

    field and oracle1in the Password field, and

    then click OK.

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    20/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 6

    2. Create the RDBMS schema or user (Oracle 11g) for the Master Repository.

    Step Screen/Page Description Choices or Values

    a. Oracle SQL Developer Execute the following SQL command in theWorksheet:

    create user snpm1 identified bypassword

    default tablespace userstemporary tablespace temp;

    Note:You can find this command in the text

    file 2-1.txtlocated in c:\LABS\Textfolder.

    Enter this command and then click thegreen, arrowhead-shaped Run Statementbutton.

    Note:In this command, password is thevalue of password to connect to usersnpm1.

    b. Oracle SQL Developer Grant connect privileges to the newly createduser account by executing the following SQLcommand:

    grant connect, resource to snpm1;

    c. Oracle SQL Developer Expand the Other Usersnode to verify thatthe snpm1 user account was successfullycreated. Minimize SQL Developer.

  • 5/20/2018 ODI 11G hand book

    21/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 7

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    22/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 8

    c.

    3. Create the ODI Master Repository:

    Step Screen/Page Description Choices or Values

    a. MS Windows Start Oracle Data Integrator: Start>Programs> Oracle > Oracle Data

    Integrator> ODI Studio.

    b. Oracle Data Integrator Open the New Gallery window by choosingFile> New.

    In the New Gallery, in the Categories tree,select ODI.

    From the Items list, select the MasterRepository Creation Wizard. Click OK.

  • 5/20/2018 ODI 11G hand book

    23/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 9

    The Master Repository Creation Wizardappears.

    c. Master Repository Creation Wizard In the Master Repository Creation Wizard,note that the JDBC Driver f ield has thecorrect selection to connect to an Oracledatabase: oracle.jdbc.OracleDriver.

    Edit the JDBC URL to read:jdbc:oracle:thin:@localhost:1521:orcl

    Specify the ODI client login username andthe database username by performing thefollowing:

    Enter the username as snpm1and thepassword as password. Enter the DBAusername as systemand the DBA passwordas oracle1.

    Click the Test Connectionbutton and verifysuccessful connection. Click OK. Click Next

    on the Master Repository Creation Wizardscreen.

    d. Master Repository Creation Wizard In the Authentication window, enter theSupervisor Password as SUNOPSIS. EnterSUNOPSISagain to confirm the password.Click Next.

    Note:Usernames and passwords arecase-sensitive in ODI.

    e. Password Storage In the Password Storage window, selectInternal Password Storage, and then clickFinish. When Master Repository is

    successfully created, you will see the OracleData Integrator Information message. ClickOK. The ODI Master Repository is nowcreated.

    f. Message Verify that ODI Master Repository wascreated successfully, and then click OK.

  • 5/20/2018 ODI 11G hand book

    24/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 10

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    25/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 11

    c.

  • 5/20/2018 ODI 11G hand book

    26/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 12

    d.

  • 5/20/2018 ODI 11G hand book

    27/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 13

    e.

    f.

    4. Connect to the ODI Master Repository by creating a new ODI Master Login:

    Step Screen/PageDescription

    Choices or Values

    a. Oracle DataIntegrator

    Open the New Gallery by selecting File> New. In the NewGallery, in the Categories tree, select ODI. From the Itemslist, select Create a New ODI Repository Login. Click OK.

    b. RepositoryConnectionInformation

    Configure the repository connection with the parameters fromthis table. To enter the JDBC URL, click the button next to theURL field and select

  • 5/20/2018 ODI 11G hand book

    28/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 14

    jdbc:oracle:thin:@::, as shown

    in the screen, then edit the URL. Select the MasterRepository onlybutton. Click the Testbutton. Verifysuccessful connection and click OK. Click OKto save theconnection.

    Oracle Data Integrator Connection

    Parameter Value

    Login Name Master Repository Pr 2-1

    User SUPERVISOR

    Password SUNOPSIS

    Database Connection (Master Repository)

    Parameter Value

    User snpm1

    Passwordpassword

    Driver List Oracle JDBC Driver

    DriverName

    oracle.jdbc.OracleDriver

    Url jdbc:oracle:thin:@localhost:1521:orcl

    Note

    Do not copy and paste in the URL field. This maycause problems with entering a valid URL string.Instead, open the drop-down menu and select thecorrect driver from the list. Type the correct URL inthe Url field.

    The ODI username (SUPERVISOR) is case-sensitive.

    c. Oracle Data

    Integrator

    Click Connect to Repository. Select the newly created

    repository connection, Master Repository Pr 2-1, from thedrop-down list. ClickOK. You are now successfully logged into the Master Repository Pr 2-1.

    d. Import ServiceDescription

    Click the Topologytab (the tab title might appear onlypartially as To). Click the Repositoriestab in the leftpanel of the Topology Manager. Verify that your newlycreated Master Repository is in the Repositories window.

  • 5/20/2018 ODI 11G hand book

    29/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 15

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    30/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 16

    c.

  • 5/20/2018 ODI 11G hand book

    31/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 17

    d.

  • 5/20/2018 ODI 11G hand book

    32/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 18

    5. Use SQL Developer to create the RDBMS schema/user for the Work repository.

    Step Screen/Page Description Choices or Values

    a. Oracle SQL Developer If SQL Developer is already opened, it mightdisplay a message about externally modifiedobjects. If so, click OKto close the message.If an earlier command is in the worksheet,

    clear the worksheet by clicking the Clearbutton that looks like a pencil eraser.

    If not opened, open SQL Developer. Createthe schema by executing the following SQLcommand:

    create user snpw1 identified bypassword

    default tablespace userstemporary tablespace temp;

    Note:You can find this command in the text

    file 2-1.txtlocated in c:\Labs\Text

    folder.Click the Run Statement button.

    b. Oracle SQL Developer Grant connect privileges to the newly createduser by executing the following SQLcommand:

    grant connect, resource to snpw1;

    c. Oracle SQL Developer Run the following command to verify that the

    snpw1 user account was successfullycreated and shown among other useraccounts in the list:

    select * from all_users;

    a.

  • 5/20/2018 ODI 11G hand book

    33/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 19

    b.

    c.

  • 5/20/2018 ODI 11G hand book

    34/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 20

    6. Now that you created the RDBMS schema/user, use ODI Topology Navigator to create theODI Work repository:

    Step Screen/PageDescription

    Choices or Values

    a. Oracle Data Integrator In ODI, click the Topology Navigatortab and then click theRepositoriespanel.

    Right-click the Work Repositoriesnode and select NewWork Repository.

    The Create Work Repository Wizard opens.

    b. Specify ODI WorkRepository ConnectionProperties

    In the screen that follows, enter the parameters shown in thefollowing table. Click the Testbutton. Verify successfulconnection and click OK. Click Next.

    Parameter Value

    Technology Oracle

    JDBCDriver

    oracle.jdbc. OracleDriver

    JDBC Url jdbc:oracle:thin:@localhost:1521:orcl

    Usersnpw1

    (notthe defaultsnpm1)

    Password password

    c. Specify ODI WorkRepository properties

    In the Specify ODI Work Repository propertiespanel, set the

    ID to 1. Set the Name to WORKREP_PR2-1. In the

    Passwordfield, enter SUNOPSIS. In the Work RepositoryTypefield, leave Developmentunchanged. Click Finish.

    Verify that the newly created Work repository is now in thework repositories tree view.

    Note:The Development type of repository enablesmanagement of design-time objects such as data modelsand projects (including interfaces, procedures, and so on). Adevelopment repository also includes the run-time objects(scenarios and sessions). This type of repository is suitablefor development environments.

    d. Create Work Repository

    Login

    In the Confirmation window, clickYes. Enter the Login

    name: Work Repository Pr 2-1. Click OK.e. Oracle Data Integrator Expand the Work Repositories node and verify that the Wor

    repository WORKREP_PR2-1 was created.

  • 5/20/2018 ODI 11G hand book

    35/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 21

    a.

    b.

  • 5/20/2018 ODI 11G hand book

    36/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 22

  • 5/20/2018 ODI 11G hand book

    37/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 23

    c.

    d.

  • 5/20/2018 ODI 11G hand book

    38/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 24

    e.

    7. Disconnect from the Master Repository and connect to the Work repository:

    Step Screen/PageDescription

    Choices or Values

    a. Oracle Data Integrator Click the ODImenu and select Disconnect MasterRepository Pr 2-1.

    b. Oracle Data Integrator Click Connect To Repository.

    c. Oracle Data IntegratorLogin

    Select Work Repository Pr 2-1from the Login Name

    drop-down list. In the Password field, enter SUNOPSIS.Click OK. Click the Designertab. Collapse the Projectsnode. The following ODI Designer screen appears.

    You have now successfully created and connected to theODI Work repository.

    d. Oracle Data Integrator Click ODI menu and select Disconnect Work repositoryPr 2-1.

    Note:You will notbe using these practice Master andWork Repositories for the remainder of this course.

  • 5/20/2018 ODI 11G hand book

    39/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 25

    a.

    b.

    c.

  • 5/20/2018 ODI 11G hand book

    40/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 2: Administering ODI Repositories

    Chapter 2 - Page 26

    d.

  • 5/20/2018 ODI 11G hand book

    41/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 1

    Practices for Lesson 3: ODITopology Concepts

    Chapter 3

  • 5/20/2018 ODI 11G hand book

    42/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 2

    Practices for Lesson 3: Overview

    Practices OverviewIn this practice, you set up and install an ODI Agent as a background service.

  • 5/20/2018 ODI 11G hand book

    43/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 3

    Practice 3-1: Setting Up and Installing an ODI Agent

    Use Case Scenario:

    John is responsible for data loading, transformation, and validation. He created Master andWork Repositories. Now he continues setting up his ODI environment by installing an ODI

    Agent.

    Background:

    A common task in ODI is to set up and install an ODI Agent as a service. After the ODIscenarios are created, they can be scheduled and orchestrated by using an ODI Agent, which isa lightweight Java process that orchestrates the execution of ODI scenarios. In this practice,you create and execute an ODI Agent, which will be used in subsequent practices fororchestration of the execution of ODI objects.

    First, you run encode to generate an encrypted password.

    You copy and paste that string into the odiparams.batfile that contains ODI agent parameters.

    You then switch to ODI, and define a physical agent named localagent. Next, you define alogical agent also named localagent, mapping it to the same-named physical agent. You specify

    the Globalcontext as the context in which to make this particular mapping of logical to physicalagents.

    In the command window, you execute agent.batto start the agent that you named localagent.

    In ODI, you test a connection to your newly created agent.

    The directions on the following pages will take you through these activities:

    1. Run encode oracle1to generate an encrypted password string

    2. Edit odiparams.bat, inserting the encrypted password

    3. In ODI, define a physical agent named localagent4. In ODI, define a logical agent named localagent, mapping it to the physical agent named

    localagentfor the Global context

    5. Execute agent.batto start an agent named localagent.

    6. Verify connection to the newly created agent localagentin ODI

  • 5/20/2018 ODI 11G hand book

    44/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 4

    Your Tasks:

    1. Before executing the agent.batfile to create the ODI Agent, you must run the encodepasswordcommand to generate an encrypted password and paste it into theodiparams.batparameter file. To do so, perform the following steps:

    Step Screen/PageDescription

    Choices or Values

    a. MS Windows andtext editor

    Open the Windows Explorer, and navigate to the ODI_HOME

    directory, where ODI is installed and open the agent\binsubdirectory:(C:\oracle\Middleware\Oracle_ODI1\oracledi\agent\bin). Navigate to the odiparams.batfile, right-click thisfile, and select Editto open it with a text editor. Leave this editoopen. You will run a batch file from a Command window andreturn to this text editor to copy the results into theodiparams.batfile.

    Explanation: You need to edit the odiparams.batfile to setthe repository connection information for the ODI Agent to use.

    The password information is stored as an encrypted string. Youwill generate the encrypted string in a Command window.

    b. Command Prompt Leave the text editor open, and open the Commandwindow(Start > Run > cmd). Change the directory to theODI_HOME\agent\bin directory:

    C:\oracle\Middleware\Oracle_ODI1\oracledi\agent\bin

    c. Command Prompt To generate the encrypted password string, you will be usingthe agent command, encode . Because your

    password is oracle1, enter and execute the followingcommand in the Command window and press ENTER:

    encode oracle1

    Note:Keep the Command window open, because you will be

    returning to it after editing the odiparams.batfile.

  • 5/20/2018 ODI 11G hand book

    45/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 5

    d. Command Promptand text editor

    Copy the generated, encrypted password from the Commandwindow (from the Command windows drop-down menu, selectEdit > Mark, then highlight the password with your mouse; then

    select Edit > Copy) and insert it into the odiparams.batfileas the value for the ODI_MASTER_ENCODED_PASSparameter(overwriting the existing password). Verify and, if necessary,edit settings for otherparameters from the following table, save

    the odiparams.batfile, and then close it. The agentsconnectivity is now set up.

    Parameter Value

    ODI_MASTER_DRIVER oracle.jdbc.OracleDriver

    ODI_MASTER_URL jdbc:oracle:thin:@localhost:1521:orcl

    ODI_MASTER_USER DEV_ODI_REPO

    ODI_MASTER_ENCODED_PASS

    Insert your encoded password.

    (overwrite the existing password)

    ODI_SECU_WORK_REP WORKREP

    ODI_SUPRVISOR_ENCODED_PASS

    Leave the default value.

    ODI_USER Leave the default value.

    ODI_ENCODED_PASS Leave the default value.

    ODI_JAVA_HOME c:\oracle\Middleware\jdk160_29

    Note

    DEV_ODI_REPO is an RDBMS schema/user (Oracle11g) for the Master Repository. It was pre-created forthis and subsequent practices.

    The Work Repository name is WORKREP.

    Because each time that you encode the password, it

    receives different values, your encoded password willdiffer from the one provided in the screen.

    Do notchange the default value of the ODI_USERandODI_ENCODED_PASSparameters. Those parameterswere pre-coded during ODI installation.

  • 5/20/2018 ODI 11G hand book

    46/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 6

    a.

    b.

    c.

  • 5/20/2018 ODI 11G hand book

    47/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 7

    d.

  • 5/20/2018 ODI 11G hand book

    48/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 8

    2. Now that you have generated an encoded password and pasted it into theodiparams.batfile, you need to create the ODI physical and logical agent definitions. Tocreate these ODI agent definitions, perform the following steps:

    Step Screen/PageDescription

    Choices or Values

    a. MS Windows

    ODI Login

    If it is not started, start Oracle Data Integrator. Click ConnectTo Repository. Select DEV_ODI_REPOfrom the LoginNamedrop-down list. Click OK.

    b. Topology navigator Click the Topologynavigator tab. In the Topology navigator,select the Physical Architecturepanel. Right-click the Agentsnode. Select New Agent.

  • 5/20/2018 ODI 11G hand book

    49/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 9

    Step Screen/PageDescription

    Choices or Values

    c. Agent: localagent Fill in the following fields:

    Name: localagent

    Host: Network name or IP address of the machine that theagent has been launched on. Verify that this parameter is set

    to localhost.

    Port: Listening port used by the agent. By default, this port is20910. Leave the default value.

    Web Application Context: Name of the Web applicationcorresponding to the Java EE agent deployed on anapplication server. For stand-alone agents, this field should beset to oraclediagent.

    Set Maximum number of sessions supported by this agent to250. Click the Savebutton.

    d. Topology NavigatorLocal Agent: New

    Now you have to insert a logical agent in Logical Architecture,and map it to the newly created Physical agent. At the bottomof the Topologynavigator tab, click the Logical Architecturetab. Right-clickAgentsand select New Logical Agent. On the

    screen that follows, set the Name to localagent. For theGlobal context, set the Physical Agents column tolocalagent. From the File menu, click Save. Close thelocalagenttab that you just worked on, leaving the otherlocalagenttab open.

    a.

  • 5/20/2018 ODI 11G hand book

    50/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 10

    b.

    c.

    d.

  • 5/20/2018 ODI 11G hand book

    51/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 11

    3. Now that you have created the agent and defined the ODI physical and logical agents, youcan start the agent directly from the command line.

    Step Screen/PageDescription

    Choices or Values

    a. Command Prompt Switch back to the Commandwindow you left open at theODI_HOME\agent\bin directory

    (C:\oracle\Middleware\Oracle_ODI1\oracledi\agent\bin). Execute the agent.batfile by using the followingcommand:

    agent -NAME=localagent

    b. Services The agent is now starting. Verify that ODI Agent is successfullystarted. Minimize (do notclose) the window CommandPrompt agent-NAME=localagent.

    Note: This command window should remain open during alllabs.

    c. Oracle DataIntegrator

    In ODI, in the localagenttab that remains open, click theTesticon to verify connection of the agent localagent.

    You successfully created and connected to ODI agent. Close

    the localagenttab . Also, close the

    Messages - Log tab.

    a.

  • 5/20/2018 ODI 11G hand book

    52/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 12

    b.

  • 5/20/2018 ODI 11G hand book

    53/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 13

    c.

  • 5/20/2018 ODI 11G hand book

    54/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 3: ODI Topology Concepts

    Chapter 3 - Page 14

  • 5/20/2018 ODI 11G hand book

    55/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 1

    Practices for Lesson 4:Describing the Physical andLogical Architecture

    Chapter 4

  • 5/20/2018 ODI 11G hand book

    56/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 2

    Practices for Lesson 4: Overview

    Practices OverviewIn this practice, you define the work infrastructure in the topology by creating contexts, a dataserver, and physical and logical schemas.

  • 5/20/2018 ODI 11G hand book

    57/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 3

    Practice 4-1: Working with Topology

    Use Case Scenario:

    John created the Master and Work Repositories and installed an ODI Agent as a backgroundservice. To complete setting up his ODI infrastructure, he needs to create contexts, a dataserver, and physical and logical schemas.

    Background:

    Before you begin working on your ODI projects, you need to describe your ODI infrastructure inthe topology. As a starting point of this practice, you will use the environment provided with theODI installation. The infrastructure includes several servers. You need to define the followingnew data server and its attached physical schemas.

    Data Server:ORACLE_ORCL_LOCAL

    Define two of three schemas available in this instance:

    Schema Description

    SALES_DEV Schema storing the target tables for developmentpurposes

    SALES_PROD Schema storing the production target tables

    STAGING Schema that is used to store ODI temporary objects(not used in this practice)

    Both the SALES_DEV and SALES_PROD physical schemas contain identical table structuresand correspond to the same logical schema called ORACLE_ORCL_LOCAL_SALES. Themapping for this logical schema depends on the context.

    Note:Completing these tasks is critical for all subsequent practice sessions.

    This practice consists of the following six steps:

    1. Define the Production context.

    2. Define the Development context. (A third context, Global, is already preseeded for you.)

    3. Define the ORACLE_ORCL_LOCALdata server.

    4. Define the ODI physical schemas for the data server: SALES_DEV, SALES_PROD.

  • 5/20/2018 ODI 11G hand book

    58/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 4

    5. Define the ORACLE_ORCL_LOCAL_SALES ODIlogical schema.

    6. Map the logical schema to the two physical schemas, in terms of the three contexts.

    Your Tasks:

    1. If not started, start Oracle Data Integrator and open the DEV_ODI_REPO connection. IfODI remains open, skip to step 2.

    Note:The username and password are case-sensitive.a. Select Start > Programs > Oracle ODI11g-Home > Oracle Data Integrator > ODI

    Studio. Click Connect To Repository.

  • 5/20/2018 ODI 11G hand book

    59/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 5

    b. Log in with the following details. Click OK.

    Login name: DEV_ODI_REPO

    User: SUPERVISOR

    Password: SUNOPSIS

    2. Create a new context:

    a. Click the Topologynavigator tab, and then click the Contextstab to expand it.

    b. Click the New Context icon on the Contextstab, and then select New Context.

    c. Enter your context parameters as shown below. The context window should appear asfollows.

    Name:Production

    Code:PRODUCTION

  • 5/20/2018 ODI 11G hand book

    60/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 6

    Password:Leave this field empty.

    Default:Select this check box, and clickYesto confirm in the pop-up window.

    d. Click the Savebutton.

    e. Create another new context , repeating the operations:

    Name:Development

    Code:DEVELOPMENT

    Password:Leave this field empty.

    Default:Leave the check box deselected.

  • 5/20/2018 ODI 11G hand book

    61/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 7

    The contexts should appear as follows:

    3. Create an ORACLE_ORCL_LOCALdata server:

    a. Click the Physical Architecturetab. Expand the Technologiesnode, scroll downand select the Oraclenode, and then right-click and select New Data Server.

    b. Enter the following information on the Definitiontab:

    Name: ORACLE_ORCL_LOCAL

    Instance / dblink (Data Server): ORCL

  • 5/20/2018 ODI 11G hand book

    62/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 8

    User: ODI

    Password: ODI

    c. Click the JDBCtab. Click the button to the right of the JDBC Driverfield. In thewindow that appears, select Oracle JDBC Driver, and then click OK.

  • 5/20/2018 ODI 11G hand book

    63/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 9

    d. Click the button to the right of the JDBC URLfield. In the URL exampleswindow,select the first URL in the Namelist, and click OK.

    e. Edit the JDBC URL to have the following:URL: jdbc:oracle:thin:@localhost:1521:ORCL

    The JDBC tab should now appear as follows:

  • 5/20/2018 ODI 11G hand book

    64/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 10

    4. Test this data server:

    a. Click the Test Connectionbutton. In the Confirmationdialog box, click OKto confirmsaving your data before testing the connection. In the Informationwindow, click OK.

    b. In the Test Connectiondialog box, click the Testbutton. In the Informationdialogbox that reports a successful connection, click OK.

  • 5/20/2018 ODI 11G hand book

    65/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 11

    5. Create a physical schema for the newly created ORACLE_ORCL_LOCALdata server. Namethe physical schema ORACLE_ORCL_LOCAL.SALES_DEV with the following parameters:

    Data Schema: SALES_DEV

    Work Schema: STAGING

    Default check box: Selected

    a. Expand the Oraclenode. Right-click the newly created data serverORACLE_ORCL_LOCAL, and then select New Physical Schema.

    b. In the new window that appears, select SALES_DEVfrom the Schema (Schema)drop-down list, and then select STAGINGfrom the Schema (Work Schema)drop-down list. Select the Defaultcheck box. In the Confirmation window that appears,

  • 5/20/2018 ODI 11G hand book

    66/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 12

    click OK. Leave all the other fields unchanged. Click the Save button . Click OKinthe Informationwindow that appears.

    c. Expand: Oracle > ORACLE_ORCL_LOCAL. The Physical schemaORACLE_ORCL_LOCAL.SALES_DEV appears in the tree view:

    6. Create a second physical schema for the ORACLE_ORCL_LOCALdata server. Name itORACLE_ORCL_LOCAL.SALES_PROD:

    Data Schema: SALES_PROD

    Work Schema: STAGING

    Default Schema: Notselected

  • 5/20/2018 ODI 11G hand book

    67/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 13

    a. Select the ORACLE_ORCL_LOCALdata server in the tree view, and then right-clickand select New Physical Schema.

    b. In the new window that appears, select SALES_PRODfrom the Schema (Schema)drop-down list, and then select STAGINGfrom the Schema (Work Schema)drop-down list. Confirm that the Default check box is notselected, and leave all the

    other fields unchanged. Click the Save button . In the Informationwindow, click

    OK.

  • 5/20/2018 ODI 11G hand book

    68/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 14

    7. Create a logical schema, ORACLE_ORCL_LOCAL_SALES, and map this schema to differentphysical schemas, for the different contexts.

    Development Context:To the ORACLE_ORCL_LOCAL.SALES_DEV physical schema

    Production Context: To the ORACLE_ORCL_LOCAL.SALES_PROD physical schema

    Global Context: To theORACLE_ORCL_LOCAL.SALES_DEV physical schema

    a. In Topology Manager, select the Logical Architecturetab and expand theTechnologiesnode. Select Oracle, right-click and select New Logical Schema.

    b. Enter the name of the logical schema: ORACLE_ORCL_LOCAL_SALES. To map thislogical schema to physical schemas in different contexts, from the drop-down lists,select the appropriate physical schema for each context, as shown in the followingscreen. Click the Savebutton.

    8. The logical schema FILE_DEMO_SRCis predefined for you and is mapped in thepredefined Global context to a physical schema that represents a subfolder in a file system.Map FILE_DEMO_SRCto the same physical schemas in the new Development andProduction contexts that you defined earlier.

  • 5/20/2018 ODI 11G hand book

    69/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 15

    a. In the Logical Architecture, expand the File node, and double-click theFILE_DEMO_SRClogical schema. Ensure that the logical schema FILE_DEMO_SRCis mapped to the physical schemas in the Development, Global, and Productioncontexts, as follows. Click the Savebutton.

    b. Repeat the previous step for the following logical schemas:

    In XML technology, the logical schema XML_DIM_GEOshould be mapped to thephysical schema XML_GEO_DIM.GEO, as follows. Click the Savebutton.

  • 5/20/2018 ODI 11G hand book

    70/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 16

    In Hypersonic SQL, the logical schema HSQL_DEMO_SRCshould be mapped tothe physical schema HSQL_LOCALHOST_20001_Defaultin all contexts.

    In Hypersonic SQL, the logical schema HSQL_DEMO_TARGshould be mapped tothe physical schema HSQL_LOCALHOST_20002_Default, as follows.

  • 5/20/2018 ODI 11G hand book

    71/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 17

    Note:Ensure that these mappings are similar in the three contexts. Close all the tabs, asshown. If you are prompted to save your changes, clickYes.

    9. You have set up ODI agent localagentin Practice 3-1. Now, link the Logical agent to thePhysical agent in all three contexts and test the connection.

    a. In the Physical Architecture, expand the Agentsnode, and open the Physical agentlocalagent. Similarly, open the Logical agent, localagent, in the Logical Architecture.Ensure that this Logical agent, localagent, is linked to Physical agent localagentin allthree contexts as follows. Save your changes.

  • 5/20/2018 ODI 11G hand book

    72/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 4: Describing the Physical and Logical Architecture

    Chapter 4 - Page 18

    b. In the Physical agents localagent tab, click Test, and verify successful connection.Click OK, and then close all the tabs.

  • 5/20/2018 ODI 11G hand book

    73/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 1

    Practices for Lesson 5:Setting Up a New ODI Project

    Chapter 5

  • 5/20/2018 ODI 11G hand book

    74/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 2

    Practices for Lesson 5: Overview

    Practices Overview

    In this practice, you create a new ODI project and import Knowledge Modules that will be usedin subsequent practice sessions.

  • 5/20/2018 ODI 11G hand book

    75/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 3

    Practice 5-1: Setting Up a New ODI Project

    Use Case Scenario:

    John is responsible for an integration project, which includes data loading, transformation, andvalidation. He created contexts, a data server, and physical and logical schemas in theTopology. To start an integration project, John needs to create a new ODI project and import

    knowledge modules that will be used for development of his project.

    Background:

    Now you assume the role of a project leader who is starting an integration project.

    You create a project named HandsOnLoads with a folder named HandsOn. You importknowledge modules for working with three sources (Hypersonic SQL, XML, and File) and onetarget (Oracle.)

    Note:Completing this practice is critical for all the following practice sessions.

    Your Tasks:

    1. Create a project, HandsOnLoads, with a folder called HandsOn.

    a. In Designer Navigator, click the Projectstab, click the New Project icon, and thenselect New Project.

  • 5/20/2018 ODI 11G hand book

    76/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 4

    b. Enter the nameof the project: HandsOnLoads. The Code field is automatically filledwith your Name field entry.

    c. Click the Save button to create the project. The project appears in the tree view.Expand the HandsOnLoads project node.

    d. ODI creates a folder named FirstFolder. Double-click this folder. In the editing windowthat appears, change the name in the Name field to HandsOn. Click Save.

  • 5/20/2018 ODI 11G hand book

    77/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 5

    2. Import the knowledge modules that are required for working with the following technologies:

    Sources:

    Hypersonic SQL, XML, File

    Targets:

    Oracle

    a. Select the HandsOnLoadsproject node. Right-click, and then select Import > ImportKnowledge Modules.

  • 5/20/2018 ODI 11G hand book

    78/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 6

    b. The Import Knowledge Modules (XML File) window appears. The File import directoryfield is f illed with the path to an XML-reference folder.

    c. Select the following knowledge modules that will be used in this project. Use the Ctrlkey and scroll down the list to make multiple selections. Be very careful in making yourselections, as there are several knowledge modules that have similar names. Click OK.

    CKM HSQL

    CKM Oracle

    IKM Oracle Incremental Update (notIKM Oracle AW Incremental Update)

    IKM SQL Control Append

    LKM File to SQL

    LKM SQL to Oracle

  • 5/20/2018 ODI 11G hand book

    79/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 7

    d. Review the Import Report, and then click Close.

    e. Check the imported knowledge modules by expanding corresponding nodes underHandsOnLoads > Knowledge Modules, as shown here:

  • 5/20/2018 ODI 11G hand book

    80/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 8

    Close the HandsOnLoads and HandsOn tabs.

    3. Now, look at global knowledge modules. Introduced in ODI 11.1.1.6, global knowledgemodules enable you to share specific knowledge modules across multiple projects.

    In previous versions of ODI, knowledge modules were always specific to a project andcould only be used within the project into which they were imported.

    A best practice is to import as global knowledge modules those that will be frequentlyused by multiple projects.

    -

    One benefit is that you only need to import the knowledge module once, rather thanimport it into each project using it.

    - Another benefit is that if you need to modify the knowledge module, the modificationwill propagate to all projects using the knowledge module.

  • 5/20/2018 ODI 11G hand book

    81/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 9

    a. In the Designer navigator, expand the Global Objectstab. Expand the GlobalKnowledge Modulesnode.

  • 5/20/2018 ODI 11G hand book

    82/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 10

    b. Right-click Loading (LKM)and select Import Knowledge Modules.

    c. The Import Knowledge Modules (XML File) window appears. Scroll down the list andselect IKM SQL to SQL Control Append. Click OK.

    d. The Import Report appears, showing IKM SQL to SQL Control Append. Click CLOSE.

  • 5/20/2018 ODI 11G hand book

    83/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 11

    e. In the Global Knowledge Modules node, expand Integration (IKM). Observe the IKMSQL to SQL Control Append knowledge module is ready to be shared among multipleprojects.

    Note:This example is to practice creating global knowledge modules. You will not be

    using this knowledge module in subsequent lab practices.

  • 5/20/2018 ODI 11G hand book

    84/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 5: Setting Up a New ODI Project

    Chapter 5 - Page 12

  • 5/20/2018 ODI 11G hand book

    85/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 1

    Practices for Lesson 6:Oracle Data Integrator ModelConcepts

    Chapter 6

  • 5/20/2018 ODI 11G hand book

    86/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 2

    Practices for Lesson 6: Overview

    Practices Overview

    In this practice, you create the models corresponding to the data, and reverse-engineer theschemas data structures.

  • 5/20/2018 ODI 11G hand book

    87/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 3

    Practice 6-1: Creating a Model

    Use Case Scenario:

    John created a new ODI project and imported knowledge modules that will be used for thedevelopment of his integration project. Now, John needs to create new ODI Models andreverse-engineer all tables and files into the models.

    Background:

    In the previous practice, you configured the schemas containing the application data stored inthe Oracle database. You now create the Oracle Sales Applicationmodel correspondingto this data and reverse-engineer the schemas data structures. You also reverse-engineer thestructure of an XML file to a Geographic Informationmodel that you define.

  • 5/20/2018 ODI 11G hand book

    88/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 4

    Your Tasks:

    1. Start the ODI Demo source environment: Select Start > Programs > Oracle > Oracle DataIntegrator > Shortcutto start the demonstration.If the Open File Security Warningwindow appears, click Run. The OracleDI Demo Source command shell window andtwo other command shell windows open.

    The ODI startdemo demonstration environment provides databases that contain someof the data used in this courses practices. Source and target data servers, as well as ademonstration repository data server, are started.

    Note:You should keep these three command shell windows running (minimized) for allremaining lab practices in this course, along with the localagent command shellwindow.

    2. Create a model for the Oracleschema.

    a. In the Designer Navigator, click the Modelstab.

  • 5/20/2018 ODI 11G hand book

    89/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 5

    b. Click the New Model icon and then select New Model.

    c. Specify (enter or select) the following parameters on the Definitiontab:

    Name:Oracle Sales Application

    Code:ORACLE_SALES_APPLICATION

    Technology:Oracle

    Logical Schema:ORACLE_ORCL_LOCAL_SALES

    The Definition tab should appear as shown:

  • 5/20/2018 ODI 11G hand book

    90/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 6

    d. Click the Reverse Engineertab, and select Developmentfrom the Context drop-downlist. Click Save.

    3. Reverse-engineer all the tables in this model.

    a. Right-click Oracle Sales Application model and select the Reverse Engineeroption. Ifthe Confirmation window appears, clickYes.

    Note:The progress of the reverse-engineering process is shown on the status bar.

  • 5/20/2018 ODI 11G hand book

    91/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 7

    b. Verify the model reverse-engineered successfully. In the tree view, expand the OracleSalesApplication model. The datastores of the model appear.

  • 5/20/2018 ODI 11G hand book

    92/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 8

    Expand the TRG_CUSTOMERdatastore, and then expand the Columnsand Constraintsnodes. The list of columns and constraints that were reverse-engineered for this tableappear in the tree view. Check that the columns and constraints that were reverse-engineered for the TRG_CUSTOMERtable correspond to its data definition language (DDL)given below. Close the tabs.

    Create table TRG_CUSTOMER (

    CUST_ID NUMERIC(10) not null,

    DEAR VARCHAR(4),

    CUST_NAME VARCHAR(50),

    ADDRESS VARCHAR(100),

    CITY_ID NUMERIC(10) not null,

    PHONE VARCHAR(50),

    AGE NUMERIC(3),

    AGE_RANGE VARCHAR(50),

    SALES_PERS VARCHAR(50),CRE_DATE DATE,

    UPD_DATE DATE,

    constraint PK_TRG_CUSTOMER primary key (CUST_ID),

    constraint FK_CUST_CITY foreign key (CITY_ID)

    references TRG_CITY (CITY_ID));

  • 5/20/2018 ODI 11G hand book

    93/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 9

    Note:The constraint called FK_SALES_CUST TRG_SALES is defined on another table.

    As it references TRG_CUSTOMER, it also appears here.

    4. Create a model for an XML file.

    a. Click the New Model icon and then select New Model.

    b. Specify (enter or select) the following parameters on the Definition tab:

    Name:Geographic Information

    Code:GEOGRAPHIC_INFORMATION

    Technology:XML Logical Schema:XML_DIM_GEO

    c. The Definition tab should appear as below. Click the Reverse Engineertab.

  • 5/20/2018 ODI 11G hand book

    94/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 10

    d. Select Developmentfrom the Context drop-down list. Click Save.

    5. Reverse-engineer all the tables in this model.

    a. In the Models tree view, right-click Geographic Information model and select the

    Reverse Engineeroption.Note:The progress of the reverse-engineering process is shown on the status bar.

  • 5/20/2018 ODI 11G hand book

    95/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 11

    b. Verify that the model reverse-engineered successfully. In the tree view, expand theGeographic Informationmodel. The datastores of the model appear.

    6. Open the XML file GEO_DIM.xmlcorresponding to the XML model that you have reverse-engineered. The file is at the following location:

    C:\oracle\Middleware\Oracle_ODI1\oracledi\demo\xmla. Open Windows Explorer, and go to the

    C:\oracle\Middleware\Oracle_ODI1\oracledi\demo\xmldirectory.

    b. Right-click the GEO_DIM.xmlfile and select Open.

    c. The XML file opens in Internet Explorer. The file structure appears as shown here:

    The file hierarchy is GEOGRAPHY_DIM > country > region > city > and so on.

  • 5/20/2018 ODI 11G hand book

    96/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 6: Oracle Data Integrator Model Concepts

    Chapter 6 - Page 12

    7. Compare the XML file content with the reverse-engineered structure in the Hierarchicalview. In Designers tree view, expand the Geographic Informationnode, and then theHierarchynode. Expand the datastores under this node.

    The hierarchy of the XML file is reproduced here. The XML file has been mapped to arelational structure, with foreign keys to map the links between the different levels ofhierarchy.

    Close the Geographic Information model tab .

  • 5/20/2018 ODI 11G hand book

    97/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 1

    Practices for Lesson 7:Organizing ODI Models andCreating ODI Datastores

    Chapter 7

  • 5/20/2018 ODI 11G hand book

    98/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 2

    Practices for Lesson 7: Overview

    Practices Overview

    In this practice, you check the quality of data in the models and define constraints on thesemodels.

  • 5/20/2018 ODI 11G hand book

    99/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 3

    Practice 7-1: Checking Data Quality in the Model

    Use Case Scenario:

    John created new ODI Models and reverse-engineered all the tables and files in the models.Now, John needs to check the quality of data in the models, define the constraints on themodels, and detect possible errors in data.

    Background:

    After the models are defined, you need to check the quality of the data in these models. In thispractice, you check the quality of data in the models and define constraints on models for thegiven sample application.

    First, you create a new model, HSQL_ORDERS_APPLICATION, as a duplicate of the modelHSQL_SRC.

    You then create a referential constraint on the SRC_CUSTOMERtables CITY_IDcolumn byusing SRC_CITYas the parent table.

    Next, you create a condition constraint on the SRC_CUSTOMERtable:

    Length(SRC_CUSTOMER.PHONE) > 6

    Note:Completing this practice is critical for all the following practice sessions.

  • 5/20/2018 ODI 11G hand book

    100/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 4

    Your Tasks:

    1. Create a new model, HSQL_ORDERS_APPLICATION, as a duplicate of the modelHSQL_SRC.

    a. In Designer, open the Modelstab. Right-click HSQL_SRCmodel and select DuplicateSelectionto duplicate the datastore. ClickYes.

    b. Open Copy of HSQL_SRCand rename it as HSQL Orders Application. For Code,

    enter HSQL_ORDERS_APPLICATION. Click Saveto save the model. If you get awarning message, clickYesto finish saving.

  • 5/20/2018 ODI 11G hand book

    101/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 5

    2. Create a Reference constraint between the SRC_CUSTOMERand SRC_CITYdatastores inthe new model. This reference is on the CITY_IDcolumn.

  • 5/20/2018 ODI 11G hand book

    102/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 6

    a. Expand the HSQL Orders Application model, and expand the SRC_CUSTOMERdatastore.

    b. Select the Constraintsnode, right-click, and select the New Referenceoption.

  • 5/20/2018 ODI 11G hand book

    103/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 7

    c. From the Tabledrop-down list, select the SRC_CITYtable. The name of the constraint

    is automatically generated. Click the Columnstab.

    d. Click the Addicon, and use drop-down lists to select the CITY_IDcolumn for bothtables of reference. (Note that the Primary Table column is City, which you want toalso change to CITY_ID.) Click Save.

  • 5/20/2018 ODI 11G hand book

    104/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 8

    3. Create a Condition constraint on SRC_CUSTOMERto check that the phone number containssix or more characters.

    a. Select the Constraintsnode again for SRC_CUSTOMER, right-click, and select the NewConditionoption.

    Enter Phone Number Lengthin the Name field.

    Select Oracle Data Integrator Conditionfrom the Type drop-down list.

    Enter the following expression in the Wherefield:

    LENGTH(SRC_CUSTOMER.PHONE) > 6

    In the Message field, enterA phone number should contain more than 6

    characters.

    Note:You can also use the Expression Editor icon to graphically edit theexpression.

    b. Click the Validation icon to validate your expression syntax.

  • 5/20/2018 ODI 11G hand book

    105/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 9

    On the Oracle Data Integration Information screen, click OK. Click Saveto add thecondition, and then close the tab.

    4. Run a static check on the HSQL Orders Application model.

    a. Select the HSQL Orders Applicationmodel tab and click the Controltab.

    b. Select the knowledge module CKM HSQL.HandsOnLoads. Click Save. Close theHSQL Orders Application model tab.

  • 5/20/2018 ODI 11G hand book

    106/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 10

    5. Select the HSQL Orders Applicationmodel in the tree view, right-click, and select Control> Check.

    a. In the Execution dialog box, select Developmentcontext and then click OK.

    b. Click OKwhen the Information dialog box notifies you that the session has started.

  • 5/20/2018 ODI 11G hand book

    107/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 11

    6. Click the Operator Navigatoricon tab . The Operator window appears.Click the Hierarchical Sessionstab. Expand the All Executionsnode. Expand the HSQLOrders Applicationsession. Expand its Stepsnode. The session should appear complete,containing steps marked with check marks and warnings, as shown here.

    Note:You can optionally review the content of this session and see the different SQLcommands issued to perform the check operations.

  • 5/20/2018 ODI 11G hand book

    108/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 7: Organizing ODI Models and Creating ODI Datastores

    Chapter 7 - Page 12

    7. Review the errors detected in the SRC_CUSTOMER datastore.

    a. Click the Designer navigator tab. On the Modelstab, expand the HSQL OrdersApplicationmodel, select the SRC_CUSTOMERdatastore, right-click, and selectControl > Errors.

    b. View the table that lists the errors detected in your table. You have one join error andseven invalid phone numbers. Each line also contains the content of the invalid record.

    c. Close these tabs.

  • 5/20/2018 ODI 11G hand book

    109/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 1

    Practices for Lesson 8: ODIInterface Concepts

    Chapter 8

  • 5/20/2018 ODI 11G hand book

    110/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 2

    Practices for Lesson 8: Overview

    Practice Overview

    In this practice, you create simple interfaces, run these interfaces, and verify the execution.

  • 5/20/2018 ODI 11G hand book

    111/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 3

    Practice 8-1: Creating ODI Interface: Simple Transformations

    Use Case Scenario:

    John created the new ODI models and reverse-engineered all the tables and files in the models,defined the constraints on the models, and checked data quality. Now, John begins working oncreating ODI Interfaces to pass data between models and perform simple data transformations.

    These interfaces will then be used for the development of his integration project.

    Background:

    After the models are defined and the quality of the data is verified, you need to create an ODIInterface to perform transformations. In this practice, you create simple interfaces with onetarget table and a single source. You will run these interfaces and check the execution.

    In this practice, you create three interfaces. First, you create an interface called INT_8-1,loading the TRG_COUNTRYdatastore in the Oracle Sales Application model with the content ofthe SRC_REGIONtable from the HSQL Orders Application model. This simple interface has notransformations.

    The second interface, INT_8-2, is a duplicate of INT_8-1, to which flow control is activated,

    and constraints in the target table are checked.The third interface, INT_8-3, loads the TRG_COUNTRYdatastore in the Oracle Sales

    Application model with the content of the SRC_CITYtable from the HSQL Orders Applicationmodel. In this interface, flow control is activated, constraints in the target table are checked, andcity population values are transformed from individual to times 1,000.

    Note:Completing this practice is critical for other practice sessions.

  • 5/20/2018 ODI 11G hand book

    112/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 4

    Your Tasks:

    1. Create an interface called INT_8-1, loading the TRG_COUNTRY datastore in the OracleSales Application model with the content of the SRC_REGIONtable from the HSQL Orders

    Applicationmodel. You must map the columns of the same name without anytransformation. Ensure that you take only distinct records.

    a. In Designer, click the Projectstab, and expand the HandsOnLoadsproject. Expand

    the HandsOn folder. Select the Interfaces node, right-click, and select the NewInterfaceoption.

    b. In the Interface window, enter INT_8-1 as the name of the interface. Ensure that theOptimization Context is Global. Click the Mappingtab.

  • 5/20/2018 ODI 11G hand book

    113/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 5

    c. In the Designer Navigator to the left, click the Modelstab. In the tree view, expand theOracle Sales Applicationmodel. Drag the TRG_COUNTRYdatastore from the treeview to the Target Datastore zone (see the following screen: the panel to the rightofthe panel with text stating Drag datastores. as sources for this dataset). Thedatastore appears in this zone.

  • 5/20/2018 ODI 11G hand book

    114/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 6

    d. Expand the HSQL Orders Applicationmodel and drag the SRC_REGIONdatastorefrom the model tree to the Sourceszone of your diagram (the panel to the leftof thetarget panel). An Automap dialog box appears. ClickYes. Now the systemautomatically maps fields in the source and target datastores.

  • 5/20/2018 ODI 11G hand book

    115/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 7

    e. Click the Flowtab. After the flow diagram initializes, you may want to use the zoom-outbutton to see all the objects in the diagram. Within the diagram, click the box for Target+ Staging Areathat is labeled Target (ORACLE_ORCL_LOCAL), then in the Target

    Area Property Inspector panel, select the Distinct Rowscheck box. If open, click the

    button to minimize the Messages log. Your screen now looks as shown here.

    Note:Confirm that the Distinct Rows check box is selected.

  • 5/20/2018 ODI 11G hand book

    116/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 8

    f. Click Saveto save your interface. If the Locking Object window appears, select Dontshow this window next time, and clickYes.

    2. Run this interface, and check the content of the TRG_COUNTRYtable.

    a. Expand the Interfaces node, right-click the newly created interface INT_8-1, and thenselect Execute.

  • 5/20/2018 ODI 11G hand book

    117/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 9

    b. Click OKin the Execution window, and then click OKwhen the Session Startedmessage appears.

    c. Click the Operatortab to open the ODI Operator Navigator. The Operator windowappears.

    Note:In Operator, you may need to click the Refresh button to view the newsession.

  • 5/20/2018 ODI 11G hand book

    118/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 10

    d. In the Session Listtab, expand the All Executionsnode. The session called INT_8-1 should appear complete. Expand this session in the tree view as shown:

  • 5/20/2018 ODI 11G hand book

    119/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 11

    e. In your interfacewindow, click the Mappingtab. In Target datastore TRG_COUNTRY, right-click COUNTRY, and then select Data.

    f. A window appears with the loaded data.

  • 5/20/2018 ODI 11G hand book

    120/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 12

    g. Verify your data and close this window. Close INT_8-1tab. If the Unlocking Objectwindow appears, select Dont show this window next time check box and click Yes.

    3. Create an interface called INT_8-2 that loads the TRG_REGION datastore in the OracleSales Application model with the content of the SRC_REGIONtable from the Orders

    ApplicationHSQL model. You must map the columns of the same name without anytransformation. Ensure that flow control is activated and all constraints in the target tableare checked.

    Note:Because this new interface uses the same source as the previous one, you willduplicate it.

    a. Click the Designertab. Expand the Projectstab, the HandsOnLoadsproject, and theHandsOnfolder. Expand the Interfacesnode and select INT_8-1. Right-click andselect Duplicate Selection, and then clickYesin the confirmation box. A copy of yourinterface appears.

  • 5/20/2018 ODI 11G hand book

    121/262

    Copyright 2012, Oracle and/or its affiliates. All rights reserved.

    Practices for Lesson 8: ODI Interface Concepts

    Chapter 8 - Page 13

    b. Double-click the interface Copy of INT_8-1to edit it.

    c. In the Namefield, change the name to INT_8-2, and then click the Mappingtab.

    d. Click the perform layout button to customize the