Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

runtime # of loop in Talend Data Mapper

Hi 

 

I am processing an incoming Mainframe file, which has data format simillar to the below xml.  In the message No_of_Transactions field will say how many number of transactions will come under that branch header. Single file will have many branch headers. I am converting the output to a Flat CSV format.

 

How can i perform loop in such scenario, by taking the value from the another key?

 

0683p000009LuZN.jpgInput DataFormat

Labels (3)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

I just depicted the input in xml format, but my source was mainframe data with fixed length data in EBCDIC format. As the expected data is 3 times and some times data comes less than that. I had the loop for 0 to 3 times. So when i receive the data less than 3, it was generating null records.

 

I have handled it with the if clause expression on the simple loop checking for not null. It worked.

View solution in original post

2 Replies
Santi2
Contributor III
Contributor III

Hi, 

If you want to save all of your transaction details you have to iterate using the Transaction_detail node as XPath loop expression and you will get all of them. Then, you can access the other elements inside the Branch_Header using relative paths.

Anonymous
Not applicable
Author

I just depicted the input in xml format, but my source was mainframe data with fixed length data in EBCDIC format. As the expected data is 3 times and some times data comes less than that. I had the loop for 0 to 3 times. So when i receive the data less than 3, it was generating null records.

 

I have handled it with the if clause expression on the simple loop checking for not null. It worked.