Hierarchical Mapper: Error with Looping Elements

Eight Stars

Hierarchical Mapper: Error with Looping Elements

I'm trying to map EDI records to a flat file, and I'm running into trouble with Looping: I can map the first several elements, but after that I get an error message saying that "the element can't be mapped because it is already looping with another element". I think I know what that means, but I'm not really sure what to do about it. Here is the error:

 

TalendLoopError.PNG

 

I've also uploaded my map, in case it helps. Thanks!

Nine Stars

Re: Hierarchical Mapper: Error with Looping Elements

Hi,

 

I cannot import your map version (My TDM version is older than yours).

 

Nontheless, there is an issue with your loop definition on your output file.

 

Currently you loop on the segment EB03 which is not what you want. Am I wrong ?

 

The question is on which input segment do you want to loop (Meaning you will have as much rows in your output file as this segement) ? ST segment ?

 

You will have to fix your loop on output file.

 

Then you will have to map REF01 and EB03 segments to your output files. As these are loop segments, you will have to set which occurence you want to get. So as to do that, you can use function AgConcatFirstPresentValue (In this function you can set a loop and filter).

 

NB: Could you upload a test input file (It will be easier to help you with an example) ?

 

Regards.

 

Eric

2019 GARTNER 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

Best Practices for Using Context Variables with Talend – Part 1

Learn how to do cool things with Context Variables

Blog

Migrate Data from one Database to another with one Job using the Dynamic Schema

Find out how to migrate from one database to another using the Dynamic schema

Blog

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog