Generate flat file with Header and Lines from 2 Readers

More
10 months 2 weeks ago #21909 by BPO
Hello,

I have tried hard but cannot find the solution, any help is welcome.
I have two data (I show them as text) :

Headers file :
HEAD1;01
HEAD2;02
HEAD3;03

Lines file :
Line1;01
Line2;01
Line3;03
Line4;02
Line5;02

I want to merge them so I can generate a file with header and line as bellow :

HEAD01
Line1
Line2

HEAD02
Line4
Line5

HEAD03
Line3

Thank you !

Please Log in or Create an account to join the conversation.

More
10 months 2 weeks ago #21910 by Peter.Jonson
Thank you for sich a good question it will benefit many of our users.

We will create a working example for you

Peter Jonson
ETL Developer

Please Log in or Create an account to join the conversation.

More
10 months 2 weeks ago - 10 months 2 weeks ago #21911 by BPO
Thank for your kind reply Peter

In your example it can be useful to generate the 3 section mainly used (Then from 3 reader in this case) so it will be representative for users :
Header
Line
Footer

Also other way to generate that kind of file (another good example you may do) is for the same result but from one reader, with data bellow :

HEAD01,Line1
HEAD01,Line2
HEAD02,Line4
HEAD02,Line5
HEAD03,Line3

Looking forward to your examples ! :)
Last edit: 10 months 2 weeks ago by BPO.
The following user(s) said Thank You: Peter.Jonson

Please Log in or Create an account to join the conversation.

More
10 months 2 weeks ago #21912 by Peter.Jonson
Here it is.

There are multiple ways of doing it. Union is the simplest option.


Peter Jonson
ETL Developer
Attachments:

Please Log in or Create an account to join the conversation.

More
10 months 2 weeks ago #21913 by Peter.Jonson
I have attached the actual transformation for your convenience.

Peter Jonson
ETL Developer
Attachments:

Please Log in or Create an account to join the conversation.

More
10 months 2 weeks ago #21914 by Peter.Jonson
Re
HEAD01,Line1
HEAD01,Line2
HEAD02,Line4
HEAD02,Line5
HEAD03,Line3

This information can be easily created using Joiner object

www.etl-tools.com/wiki/aetle/processing_.../working_with_joiner

Peter Jonson
ETL Developer

Please Log in or Create an account to join the conversation.

Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Read more
Marketing
Set of techniques which have for object the commercial strategy and in particular the market study.
Google
Accept
Decline
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Functional
Tools used to give you more features when navigating on the website, this can include social sharing.