Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
AudreyRene
Helper I
Helper I

Adding value totals to my power bi visualization

Hello,

 

I'm currently working on a project. I want to show the total entries in my visual (sum of the transaction). I dont want to add a new column into this visualization, i want to put the total on the right. I also want to add this value to my table. How can i do it ?

 

AudreyRene_2-1714143846529.png

AudreyRene_0-1714143807366.png

AudreyRene_1-1714143814517.png

 

1 ACCEPTED SOLUTION
kpost
Super User
Super User

After getting a better idea of what exactly you are trying to do, I have built a solution for what I would do in this situation.

 

Since you cannot include totals in the built-in "View as table" option, I would build both the line chart and the table, then use bookmarks to display one or the other.  This has the added benefit of allowing you to format the table however you prefer. 

 

Since you cannot include the total on the line graph, I would add a card visual 'in front of' the graph, and format the graph so that the line never goes 'behind' that card.  To achieve that, I made the maximum value of the Y axis a function equal to " MAX(Y Axis) * 1.15 " to make room for the "Total" card visual on the top right of the Line Graph.  You may have to modify this measure depending on your situation, but that's the general idea, assuming you want there to be a 'total' value displayed and you want it to be taller than the space the line graph has for the title of the line graph.  In the image you posted, your title font is pretty small, and the area you highlighted is on top of the area allocated for the line graph, so that's why I did this.

 

See attached .pbix file with the solution I would build for this situation.    To click the buttons in Power BI Desktop, hold down Ctrl before you click.

view2.png

view1.png

  

/// Mediocre Power BI Advice, but it's free ///

View solution in original post

4 REPLIES 4
kpost
Super User
Super User

After getting a better idea of what exactly you are trying to do, I have built a solution for what I would do in this situation.

 

Since you cannot include totals in the built-in "View as table" option, I would build both the line chart and the table, then use bookmarks to display one or the other.  This has the added benefit of allowing you to format the table however you prefer. 

 

Since you cannot include the total on the line graph, I would add a card visual 'in front of' the graph, and format the graph so that the line never goes 'behind' that card.  To achieve that, I made the maximum value of the Y axis a function equal to " MAX(Y Axis) * 1.15 " to make room for the "Total" card visual on the top right of the Line Graph.  You may have to modify this measure depending on your situation, but that's the general idea, assuming you want there to be a 'total' value displayed and you want it to be taller than the space the line graph has for the title of the line graph.  In the image you posted, your title font is pretty small, and the area you highlighted is on top of the area allocated for the line graph, so that's why I did this.

 

See attached .pbix file with the solution I would build for this situation.    To click the buttons in Power BI Desktop, hold down Ctrl before you click.

view2.png

view1.png

  

/// Mediocre Power BI Advice, but it's free ///

kpost
Super User
Super User

Edit:  This solution is not what AudreyRene was looking for.  See my other response for a workable solution.

 

For the line graph, there is no way to add a 'total' that sums all of the individual values.  You will have to add the 'Total' measure to another visual like a 'Card' and put it 'in front of' the line graph.

In the Table, any value that is formatted as whole numbers or decimals should automatically have a total value.

But to manually turn it on, follow these steps

>Format your Visual

->Totals

>turn Values "On"

Also, make sure that Summarization for that field is activated.

 

pic2.png

pic1.png

  

 

Hello,

 

I think my explanation wasn't clear. I can see the total when i choose the visualization table 

 

AudreyRene_0-1714148074474.png

 

The problem is when i choose another visualization, select the ... (right corner) and display as table. This table doesnt have any total. I want a total here.

 

AudreyRene_1-1714148193194.png

AudreyRene_2-1714148287910.png

 

 

ohhh, I see.  I don't believe that is possible.

 

I would just build the table as a visual, then use bookmarks and create a "View as Table" and "View as Line Graph" buttons

 

I will respond in a few moments with a .pbix file solving your problem the way I would do it.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.