locked
Transform Data - using Transpose, Pivot and Unpivot RRS feed

  • Question

  • Hi, I am trying to transform the below table:

      Date1 Date1 Date1 Date2 Date2 Date2 Date3 Date3 Date3
      Col1 Col2 Col3 Col1 Col2 Col3 Col1 Col2 Col3
    Row1 Row1-Date1-Col1 Row1-Date1-Col2 Row1-Date1-Col3 Row1-Date2-Col1 Row1-Date2-Col2 Row1-Date2-Col3 Row1-Date3-Col1 Row1-Date3-Col2 Row1-Date3-Col3
    Row2 Row2-Date1-Col1 Row2-Date1-Col2 Row2-Date1-Col3 Row2-Date2-Col1 Row2-Date2-Col2 Row2-Date2-Col3 Row2-Date3-Col1 Row2-Date3-Col2 Row2-Date3-Col3
    Row3 Row3-Date1-Col1 Row3-Date1-Col2 Row3-Date1-Col3 Row3-Date2-Col1 Row3-Date2-Col2 Row3-Date2-Col3 Row3-Date3-Col1 Row3-Date3-Col2 Row3-Date3-Col3

    To the following:

        Col1 Col2 Col3
    Row1 Date1 Row1-Date1-Col1 Row1-Date1-Col2 Row1-Date1-Col3
    Row2 Date2 Row2-Date2-Col1 Row2-Date2-Col2 Row2-Date2-Col3
    Row3 Date3 Row3-Date3-Col1 Row3-Date3-Col2 Row3-Date3-Col3

    I am able to do the transform when there is only 1 column under each date, but not able to do so when there are multiple columns associated with each date. Would really appreciate if somebody can help me. Thanks in advance!

    Thursday, September 24, 2020 4:29 PM

Answers