Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi there,
I am looking for a way to convert column's value to row value.
This is an input sample.
(In the actual case, I have these data inside a database)
input
And this is the expected output.
I wanted to move the value from repeating column(w/ difference seq no.) to the corresponding column.
expected out
I heard about tUnpivotRow component, but I'm using Talend Cloud Studio (v 7.3), but I couldn't find pivot component.
Can anyone show me the JobDesign(screenshot) for achieving the expected output?
Here is the two method I tried.
1) Using tUnpivot
Job Design and Result
unpivot -- job design and result vs
expected out
Here, there are a few problems...
1) the column header (id, key1, value1) becomes a part of a row value....
2) the repeating column header (key2, value2, key3 ....) is still there
3)
1.1 DBInput Schema
unpivot -- dbInput's schema
1.2 tUnpivotRow's Schema
unpivot -- tUnpivotRow's Schema
1.3 tMap
unpivot -- tMap
2) tNormalize
Job Design and Result
normalize -- job design and result
Here, there are few problems
1) 'key' and 'value' is not separated into a different column
2) manual mapping is needed == inflexible
3) id's auto increment is not working....
1.1 DBInput's Schema
normalize-- dbInput's schema
1.2 tMap
normalize -- tMap
1.3 tNormalize's Schema
normalize -- tNormalize's Schema
Thank you