Introduction to Steps Introduction to Packages

Working with Packages 10-5 4. Click the step icon in the diagram. The properties panel opens.

5. In the General tab, edit the Step Name field.

6. From the File menu, click Save.

10.3.1.2 Executing a Procedure

To insert a Procedure step:

1. Open the Package editor and go to the Diagram tab.

2. Select the procedure to add to the Package from the Designer Navigator Projects

tree.

3. Drag and drop the procedure into the diagram. A procedure step appears.

4. Click the step icon in the diagram. The properties panel opens.

5. In the General tab, edit the Step Name field.

6. In the Options tab, set the procedure options if needed.

7. From the File menu, click Save.

10.3.1.3 Variable Steps

There are different variable steps within Oracle Data Integrator: ■ Declare Variable : When a variable is used in a Package or in elements of the topology which are used in the Package, it is strongly recommended that you insert a Declare Variable step in the Package. This step explicitly declares the variable in the Package. ■ Refresh Variable : This step refreshes the variable by running the query specified in the variable definition. ■ Set Variable : There are two functions for this step: ■ Assign sets the current value of a variable. ■ Increment increases or decreases a numeric value by the specified amount. ■ Evaluate Variable : This step compares the value of the variable with a given value according to an operator. If the condition is met, then the evaluation step is true, otherwise it is false. This step allows for branching in Packages. Declaring a Variable To insert a Declare Variable step:

1. Open the Package editor and go to the Diagram tab.

2. In Designer Navigator, select the variable to add to the Package from the Projects

tree for a project variable or from the Others tree for a global variable. 3. Drag and drop the variable into the diagram. A variable step appears. 4. Click on the step icon in the diagram. The properties panel opens.

5. In the General tab, fill in the Step Name field. Select Declare Variable in the Step

Type.

6. From the File menu, click Save.

Refreshing a Variable To insert a Refresh Variable step: 10-6 Oracle Fusion Middleware Developers Guide for Oracle Data Integrator

1. Open the Package editor and go to the Diagram tab.

2. In Designer Navigator, select the variable to add to the Package from the Projects

tree for a project variable or from the Others tree for a global variable. 3. Drag and drop the variable into the diagram. A variable step appears. 4. Click on the step icon in the diagram. The properties panel opens.

5. In the General tab, fill in the Step Name field. Select Refresh Variable in the Step

Type.

6. From the File menu, click Save.

Setting a Variable To insert a Set Variable step:

1. Open the Package editor and go to the Diagram tab.

2. In Designer Navigator, select the variable to add to the Package from the Projects

tree for a project variable or from the Others tree for a global variable. 3. Drag and drop the variable into the diagram. A variable step appears. 4. Click on the step icon in the diagram. The properties panel opens.

5. In the General tab, fill in the Step Name field. Select Set Variable in the Step Type.

6. Select Assign or Increment depending on the operation you want to perform on

the variable value.

7. Type in the Value field the value to set or the increment. This value may be

another variable.

8. From the File menu, click Save.

Evaluating a Variable To insert an Evaluate Variable step:

1. Open the Package editor and go to the Diagram tab.

2. In Designer Navigator, select the variable to add to the Package from the Projects

tree for a project variable or from the Others tree for a global variable. 3. Drag and drop the variable into the diagram. A variable step appears. 4. Click on the step icon in the diagram. The properties panel opens.

5. In the General tab, fill in the Step Name field. Select Evaluate Variable in the Step

Type.

6. Select the Operator used to compare the variable value.

7. Type in the Value field the value to compare with your variable. This value may be

another variable.

8. From the File menu, click Save.

Note: You can specify a list of values in the Value field. When using the IN operator, use the semicolon character ; to separate the values of a list. Working with Packages 10-7 An evaluate variable step can be branched based on the evaluation result. See Section 10.4, Defining the Sequence of Steps for more information on branching steps.

10.3.1.4 Adding Oracle Data Integrator Tool Steps

Oracle Data Integrator provides tools that can be used within Packages for performing simple operations. The tools are either built-in tools or Open Tools that enable the user to enrich the data integrator toolbox. To insert an Oracle Data Integrator Tool step:

1. Open the Package editor and go to the Diagram tab.

2. From the Package Toolbox, select the tool that you want to use. Note that Open

tools appear in the Plugins group. 3. Click in the Package diagram. A step corresponding to your tool appears.

4. In the General tab of the properties panel, fill in the Step Name field.

5. Set the values for the parameters of the tool. The parameters descriptions appear

when you select one, and are detailed in Appendix A, Oracle Data Integrator Tools Reference .

6. You can edit the code of this tool call in the Command tab.

7. From the File menu, click Save.

The following tools are frequently used in Oracle Data Integrator Package: ■ OdiStartScen : starts an Oracle Data Integrator scenario synchronously or asynchronously. To create an OdiStartScen step, you can directly drag and drop the scenario from the Designer Navigator into the diagram. ■ OdiInvokeWebService : invokes a web service and saves the response in an XML file. ■ OS Command : calls an Operating System command. Using an operating system command may make your Package platform-dependant. The Oracle Data Integrator tools are listed in Appendix A, Oracle Data Integrator Tools Reference .

10.3.1.5 Model, Sub-Models and Datastore Related Steps

You can perform journalizing, static check or reverse-engineering operations on models, sub-models, and datastores. The process for creating these steps are described in the following sections.

10.3.1.6 Checking a Model, Sub-Model or Datastore

To insert a check step in a Package: Note: When setting the parameters of a tool via the steps properties panel, graphical helpers allow value selection in a user-friendly manner. For example, if a parameter requires a project identifier, the graphical interface will redesign it and display a list of project names for selection. By switching to the Command tab, you can review the raw command and see the identifier.