Forum Discussion
DouweMeer
2 years agoImpactful Individual
Unpivoting clustered columns
Like, currently I have it like this: Id V1 V2 V3 A1 A2 A3 B1 B2 B3 1 v1.1 v2.1 v3.1 a1.1 a2.1 a3.1 b1 .1 b2 .1 b3.1 2 v1.2 v2.2 v3.2 a1.2 a2.2 a3.2 b1 .2 b2 .2 ...
spinfuzer
2 years agoSolution Sage
Unpivot
Split Attribute from Non Digit to Digit to end up with Attribute.1 and Attribute.2
Split the Attribute.2 from Digit to non digit to get rid of the extra ":" if it exists.
Do any additional clean up on Attribute.1 and attribute 2.1 that you need to properly pivot your data into the correct columns.
Then pivot.