Forum Discussion

MathiasChaparro's avatar
MathiasChaparro
Frequent Visitor
2 years ago
Solved

Dynamic Column Headers in matrix - Report Server

Hi everyone:   I would like the matrix headers to be partly static and partly dynamic. Like this below     The base structure is simple, I have a fact table, a calendar table and several ...
  • MathiasChaparro's avatar
    2 years ago

    Hello Community:

    I found the solution using Power Query.

     

    I duplicate my "Calendar" table and leave only the "Fin de Mes" field, then add conditional columns to find the previous month and previous year using the functions "Date.Add.Years and Date.AddMonths"

     

     

    As a next step, unpivot columns and add an index to sort the table according to my requirement.

    And as a last step I created a measure to contain the values ​​I need in each column

     

    It works perfectly and is what the user was looking for! Thank you for reading 😊