Forum Discussion

bhattshubham's avatar
bhattshubham
Frequent Visitor
5 years ago
Solved

Dynamic Columns in table visual based on slicer selection

Hi I am looking to create a table in PowerBI desktop which should dynamically show columns based on the slicer. i.e If in the Commodity Slicer "Com 1" is selected, the columns corresponding to onl...
  • v-yalanwu-msft's avatar
    5 years ago

    Hi bhattshubham ,  

    Currently, slicer cannot based on columns name. To work around this issue, you could Unpivot your table. Please refer to the steps below:

    1.Unpivot table(select ColumnCom 1 - Attribute 1” to “Com 2 - Attribute 3”>Unpivot Columns)

    2.Remove empty

    3.Result

    4.Now you can create a matrix and filter your data in slicer by Commodity column.

    Best Regards,
    Community Support Team_ Yalan Wu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.