mapping 2 separate input fields to one field in data mapper

Highlighted
Four Stars

mapping 2 separate input fields to one field in data mapper

Hi

 

I am completely new to Talend, so please bear with me Smiley Happy

 

I have a simple input file in with 2 separate fields that should be mapped to the same field in the xsd. I am trying to achieve this using data mapper.  

 

This drawing illustrates what I am trying to achieve:

mapping.png

Since talend does not allow me to drag n drop to the same field I guess this requires some sort of looping, but I am yet to find out how to do this. 

 

Could you please provide me with some guidance on how exactly to do this? 

 

Thanks in advance

 

 

 

Forteen Stars

Re: mapping 2 separate input fields to one field in data mapper

@Wookie,in tmap you can concantenate.

 

row1.field+" "+row2.field

Manohar B
Don't forget to give kudos/accept the solution when a replay is helpful.
Four Stars

Re: mapping 2 separate input fields to one field in data mapper

Thanks for the suggestion, but I cannot imagine that will help since I am not trying to merge the fields by rather repeat/loop them. Let me clarify:

 

if you take a look at the output schema the field I am trying to map to is nested. It looks like this (simplified)

 

<organisationAssociations>
    <organisation>
             <v3:source_id>ENTRIES FROM ORG</v3:source_id>
      </organisation>
</staffOrganisationAssociation>

What I am trying to do is get this: 

 

<organisationAssociations>
    <organisation>
             <v3:source_id>ORG1</v3:source_id>
      </organisation>
</staffOrganisationAssociation>

<organisationAssociations>
    <organisation>
             <v3:source_id>ORG2</v3:source_id>
      </organisation>
</staffOrganisationAssociation>

 

Is that possible? 

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

6 Ways to Start Utilizing Machine Learning with Amazon We Services and Talend

Look at6 ways to start utilizing Machine Learning with Amazon We Services and Talend

Blog