Configuring the components - 7.0

Processing (Integration)

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
EnrichPlatform
Talend Studio
task
Data Governance > Third-party systems > Processing components (Integration)
Data Quality and Preparation > Third-party systems > Processing components (Integration)
Design and Development > Third-party systems > Processing components (Integration)

Procedure

  1. Double-click tFixedFlowInput to open its Basic settings view.
  2. Select Use Inline Content (delimited file) in the Mode area.
  3. In the Content field, enter the data to pass to tWriteDynamicFields, for example:
    1;Andy;Doc
    2;Anderson;Dev
  4. Click the Edit schema button to open the schema editor.
  5. Click the [+] button to add three columns, namely id, name, and dept, of the Integer and String types respectively.
  6. Click OK to validate the setup and close the editor.
  7. Double-click tWriteDynamicFields to open its Basic settings view.
  8. Click the Edit schema button to open the schema editor.
  9. Click the [+] button in the right panel to add two columns, namely id and dynamic, of the Integer and Dynamic types respectively.
    The column id contains the value of the column id from tFixedFlowInput and the column dynamic contains the values of the columns name and dept from tFixedFlowInput.
  10. Click OK to validate the setup and close the editor.
  11. Double-click tLogRow to open its Basic settings view.
    Select Table (print values in cells of a table) for a better display of the results.
  12. Double-click tJavaRow to open its Basic settings view.
  13. In the Code field, enter the Java code to extract the contents of the dynamic column dynamic:
    Dynamic columns = row3.dynamic;
     
    for (int i = 0; i < columns.getColumnCount(); i++) {  
        DynamicMetadata columnMetadata = columns.getColumnMetadata(i);  
        System.out.println(columnMetadata.getName() + ": " + 
    columns.getColumnValue(i) + "; " + columnMetadata.getType());
    } 
    The dynamic column dynamic of the flow row3 is specified for retrieving the names, values and types of columns that it contains.