Forum Discussion

Zer0Fear1's avatar
Zer0Fear1
Regular Visitor
1 year ago
Solved

Add a Grand Total column to a stacked column chart

I have a stacked column chart showcasing cost by month, but I want to show the grand total of all months below the x axis. How can I do this?

 

I realize my example only shows November, but when I show other dates I'd like to have it total up. 

 

 

 

  • Hi Zer0Fear1 ,

    Thanks for connecting with the Microsoft Fabric Community Forum.

     

    Try using this DAX query, it will work for you. Here is the DAX Measure you can use

    Grand Total = SUM(sheet1'[Cost])

                                 (or)

    Grand Total Series = CALCULATE(SUM('YourTable'[Cost]), ALL('YourTable'[Date]))

    Now, you can add Grand total  to the card visual and view.

     

    For your Idea, I’ve attached the PBIX file with the implemented solution. Please review it and let us know is there any further questions.

    If you have any further questions or updates regarding your issue, feel free to ask, and we will look into that.

     

    Please Accept as solution If this post clears your issue and a Kudos would be appreciated.

    Thankyou.

     

2 Replies

  • Hi Zer0Fear1 - you can create a DAX measure that calculates the total cost across all months

    Grand Total = SUM('YourTable'[Cost])

    Insert a card visual below your chart.Use the Grand Total measure as the value in the card position the card under the x-axis of your chart.

    make sure that the chart's axis labels do not overlap with the total.Use contrasting colors to make the grand total stand out from monthly costs.If many dates are shown, consider using grouping or a summary level for months to make the chart clearer.

     

    Hope this helps.

     

  • v-sgandrathi's avatar
    v-sgandrathi
    Icon for Community Support rankCommunity Support

    Hi Zer0Fear1 ,

    Thanks for connecting with the Microsoft Fabric Community Forum.

     

    Try using this DAX query, it will work for you. Here is the DAX Measure you can use

    Grand Total = SUM(sheet1'[Cost])

                                 (or)

    Grand Total Series = CALCULATE(SUM('YourTable'[Cost]), ALL('YourTable'[Date]))

    Now, you can add Grand total  to the card visual and view.

     

    For your Idea, I’ve attached the PBIX file with the implemented solution. Please review it and let us know is there any further questions.

    If you have any further questions or updates regarding your issue, feel free to ask, and we will look into that.

     

    Please Accept as solution If this post clears your issue and a Kudos would be appreciated.

    Thankyou.