Step 4: Outputing the selected data stream - 7.0

Data Integration Job Examples

author
Talend Documentation Team
EnrichVersion
7.0
EnrichProdName
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 ESB
Talend Open Studio for MDM
Talend Real-Time Big Data Platform
task
Design and Development > Designing Jobs
EnrichPlatform
Talend Studio

Procedure

  1. Drop a tFileOutputDelimited component onto the design workspace, and double-click it to open the Basic settings view to set its component properties.
  2. Select the Use Output Stream check box to enable the Output Stream field and fill the Output Stream field with the following command:
    (java.io.OutputStream)globalMap.get("out_file")
    Note:

    You can customize the command in the Output Stream field by pressing Ctrl+Space to select built-in command from the list or type in the command into the field manually in accordance with actual practice. In this scenario, the command we use in the Output Stream field will call the java.io.OutputStream class to output the filtered data stream to a local file which is defined in the Code area of tJava in this scenario.

  3. Connect tFileInputDelimited to tMap using a Row > Main connection and connect tMap to tFileOutputDelimited using a Row > out1 connection which is defined in the Map Editor of tMap.
  4. Click Sync columns to retrieve the schema defined in the preceding component.
  5. Drop a tLogRow component onto the design workspace, and double-click it to open its Basic settings view.
  6. Select the Table radio button in the Mode area.
  7. Connect tFileOutputDelimited to tLogRow using a Row > Main connection.
  8. Click Sync columns to retrieve the schema defined in the preceding component.

    This Job is now ready to be executed.

  9. Press Ctrl+S to save your Job and press F6 to execute it.

    The content of the selected data is displayed on the console.

    The selected data is also output to the specified local file customerselection.txt.