Forum Discussion

Zuy_NA's avatar
Zuy_NA
Regular Visitor
5 years ago
Solved

Combine column

Dear HotChilli ,

Please help me to transfer data like this:

ClassName1Name2Name3Name4Name5Score1Score2Score3Score4Score5
1A    6    
2B    7    
3CA   89   
4DABCA53437

Into:

ClassNameScore
1A6
2B7
3C8
3A9
4D5
4A3
4B4
4C3
4A7

 

Thanks,

Best regards,

  • Hello Zuy_NA 

     

    In Power Query, select the Class column and 'Unpivot other columns'.

    Filter out the blank values in the Values column (use the dropdown).

    Use 'split by delimiter' on the attribute column (Using 'By Non-digit to digit').

    Select the 'Attribute1' column and choose Pivot from the Transform menu. Choose Value for the Values column and 'Don't aggregate' from the Advanced section. 

1 Reply

  • HotChilli's avatar
    HotChilli
    Community Champion

    Hello Zuy_NA 

     

    In Power Query, select the Class column and 'Unpivot other columns'.

    Filter out the blank values in the Values column (use the dropdown).

    Use 'split by delimiter' on the attribute column (Using 'By Non-digit to digit').

    Select the 'Attribute1' column and choose Pivot from the Transform menu. Choose Value for the Values column and 'Don't aggregate' from the Advanced section.