Scenario 1: Using context parameters when reading a table from an Oracle database - 6.1

Talend Components Reference Guide

Talend Big Data
Talend Big Data Platform
Talend Data Fabric
Talend Data Integration
Talend Data Management Platform
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Open Studio for Big Data
Talend Open Studio for Data Integration
Talend Open Studio for Data Quality
Talend Open Studio for ESB
Talend Open Studio for MDM
Talend Real-Time Big Data Platform
Talend Studio
Data Governance
Data Quality and Preparation
Design and Development

In this scenario, we will read a table from an Oracle database using a context parameter to refer to the table name.

Dropping and linking the components

  1. Create a new Job and add the following components by typing their names in the design workspace or dropping them from the Palette: a tOracleInput component and a tLogRow component.

  2. Connect tOracleInput to tLogRow using a Row > Main link.

Configuring the components

  1. Double-click tOracleInput to open its Basic Settings view in the Component tab.

  2. Select a connection type from the Connection Type drop-down list. In this example, it is Oracle SID.

    Select the version of the Oracle database to be used from the DB Version drop-down list. In this example, it is Oracle 12-7.

    In the Host field, enter the Oracle database server's IP address. In this example, it is

    In the Database field, enter the database name. In this example, it is TALEND.

    In the Oracle schema field, enter the Oracle schema name. In this example, it is TALEND.

    In the Username and Password fields, enter the authentication details.

  3. Click the [...] button next to Edit schema to open the schema editor.

  4. Click the [+] button to add four columns: ID and AGE of the integer type, NAME and SEX of the string type.

    Click OK to close the schema editor and accept the propagation prompted by the pop-up dialog box.

  5. Put the cursor in the Table Name field and press F5 for context parameter setting. The dialog box [New Context Parameter] pops up.

    For more information about context settings, see Talend Studio User Guide.

  6. In the Name field, enter the context parameter name. In this example, it is TABLE.

    In the Default value field, enter the name of the Oracle database table to be queried. In this example, it is PERSON.

  7. Click Finish to validate the setting.

    The context parameter context.TABLE automatically appears in the Table Name field.

  8. In the Query Type list, select Built-In. Then, click Guess Query to get the query statement.

    FROM "+context.TABLE
  9. Double-click tLogRow to open its Basic settings view in the Component tab.

  10. In the Mode area, select Table (print values in cells of a table) for a better display of the results.

Save and executing the Job

  1. Press Ctrl + S to save the Job.

  2. Press F6 to run the Job.

    As shown above, the data in the Oracle database table PERSON is displayed on the console.