cancel
Showing results for 
Search instead for 
Did you mean: 

Need help on the scenario

venkataramana_paidi
Contributor
0 Kudos

Hi ,

I have some source data  and target as shown below.

Input :
2011_01 2011_02 2011_03
col1col2col1col2col1col2
103010807090
204030402050
Output:
MONTH_IDcol1col2
2011_011030
2011_012040
2011_021080
2011_023040
2011_037090
2011_032050

I cannot use pivot transform also as input has not in the desired format.

How can i achieve this output.

Please help me in the logic.

Thanks & Regards,

Ramana.

Accepted Solutions (1)

Accepted Solutions (1)

RiccardoBrogi
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Ramana,

you can simply use three different queris (one query for every data source) in which you add an additional column in which you "hard-code" the source name.

After this, you can merge the results of the three queries and obtain the desired output.

Best,

Riccardo

0 Kudos

I found another way we could achieve the same.

Read all source files using single flat file format with wildcard character(*) and use the source information property of the flat file format to pull the source file name as below:

Once we are good with reading all the sources connect it to a query where we can trim the file extensions using rtrim function. Below screenshot

Data flow design as:

Cheers/Santhosh

Answers (0)