Forum Discussion

Optimusprime_25's avatar
Optimusprime_25
Resolver I
2 years ago

Issue with Stacked Colum Chart

I have a requirement where I have to show data in a Stacked Column Chart.

In X-axis I have current year MTD and previous year MTD, basically those are measures.

In Y axis I have to show data according to the Product.(Dimension)

In Product I have 3 different categories in product which are A,B and C.

So now I have to show data for current year sales mtd 2024 and previous year sales mtd 2023 in X axis for different categories (product) in Y axis

7 Replies

    • Optimusprime_25's avatar
      Optimusprime_25
      Resolver I

      Asper requirement we have to show the data in stacked column chart but the data which we have we couldn't able to show that.

      In Stacked column chart we can show only categories in X axis and in Y axis we can show only measures, butaccording to the reuirement we have to show vice versa.

      we have to show previous year mtd and current year mtd in x axis and Categories in Y axis.

      • Anonymous's avatar
        Anonymous
        Not applicable

        Hi Optimusprime_25 ,

        I create a table and two simple measures as you mentioned.

        mtd 2023 = CALCULATE(SUM('Table'[2023-1])+SUM('Table'[2023-2]))
        mtd 2024 = CALCULATE(SUM('Table'[2024-1])+SUM('Table'[2024-2]))

        When we select the Stacked column chart, we can not let the mesures in X-axis. We just can let them in Y-axis.

        I think you can use Stacked bar chart. It can let the measures in X-axis.

        It can also get what you want.

         

         

        Best Regards

        Yilong Zhou

        If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.