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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Report tooltip page not showing correct data

Hello everyone,

@dhruvinushah , as you have suggested, I have added some details of what I am trying to achieve and the issue that I am facing.

Edited: I have attached the screenshots below. All the columns are from one table. All the slicers are also from the same table.

I have a tooltip page which is supposed to show the percentage of total of an element (category) when hovering over the element(category) of a donut chart. I have a measure which does this perfectly. However when I use the category field in the tooltip fields section by disabling "keep filters" option, suddenly the numbers are wrong. On further inspection I found out that the numerator of the percentage calculation is right but the denominator is wrong. I have syned the filters on the tooltip page with the ones from the source page as well. I am not able to debug the issue with my measure. Is there another way for the tooltip to appear for my visual on the source page without the tooltips fields section. I just want to show the percentage of total for each category.

I want to show percentage of total for a category when I hover over the category.

 

powerbi_donut.PNG

 

The below screenshot shows the filters that I have taken from the source page where the above donut chart is present and I have also synced the filters.

powerbi_report_tooltip.PNG

Just to mention, there is one filter that I haven't taken from the source page which is based on a completely different measure and will not affect us in any way.

Now I have shown the denominator and the percentage in two separate cards.

When I turn off the "keep filters" option and don't include any column from my table in the tooltips fields section, then the denominator is showing the right value but the percentage is always 100 %.

When I either turn off the "keep filters" option and include the "products" column in the tooltips field section or do it the other way around, I do get a percentage but it's wrong since the denominator is wrong. The numerator however is always right.

 

This is the measure used to calculate the percentage of total for a category. I thought that removing the "product" column from the denominator will solve the problem, but it doesn't.

powerbi_measure.PNG

Any suggestions or techniques to solve this is highly appreciated. Thank you in advances for all the responses.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hello everyone,

First of all thank you @dhruvinushah for your help. I believe that being a beginner there are a lot of things where I have messed up. To begin with, I had made use of a single table for the entire dasbhoard which is a blunder since we should be following a star schema based data modelling in most of the scenarios. Due to this reason, I think I was facing this issue due to the built-in feature of DAX called auto-exist, since all of my slicers were from columns that came from the same table.

You can read more about it here: https://www.sqlbi.com/articles/understanding-dax-auto-exist/

And to start following some of the basic and the most important data modelling principles here:

https://radacad.com/build-your-first-star-schema-model-in-action-power-bi-modeling-basics.

This link above is the final blog in a series of blogs but it has pre-requisite links to help you understand the modelling principles.

 

Thanks and Regards,

Anant Shukla.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hello everyone,

First of all thank you @dhruvinushah for your help. I believe that being a beginner there are a lot of things where I have messed up. To begin with, I had made use of a single table for the entire dasbhoard which is a blunder since we should be following a star schema based data modelling in most of the scenarios. Due to this reason, I think I was facing this issue due to the built-in feature of DAX called auto-exist, since all of my slicers were from columns that came from the same table.

You can read more about it here: https://www.sqlbi.com/articles/understanding-dax-auto-exist/

And to start following some of the basic and the most important data modelling principles here:

https://radacad.com/build-your-first-star-schema-model-in-action-power-bi-modeling-basics.

This link above is the final blog in a series of blogs but it has pre-requisite links to help you understand the modelling principles.

 

Thanks and Regards,

Anant Shukla.

Anonymous
Not applicable

I was wondering if there is a way to pass the context from the source page visualization to the report tooltip page without making use of "keep filters" option or choosing columns for the tooltip fields so that when I hover over a category in the source page visual, the context will accordingly affect the measure in the report tooltip page. Please let me know if this is possible.

Anonymous
Not applicable

Thank you for the quick response @dhruvinushah . I have all of my columns in the same table unlike what you show in your query where I can see two tables, one for sales and one for product. Also I think it's the combination of other columns in the table acting as filters which are causing me trouble. I have also tried what you suggest in your answer. Can you please show me an example where all of your columns originate from the same table and a couple of other columns from the same table acting as filters. Also I would like to mention that my denominator changes for different categories for a particular combination of slicers which shouldn't be happening.

dhruvinushah
Responsive Resident
Responsive Resident

Hi @Anonymous , 
Thanks for sharing the screenshots and other information. 
I tested the measure you created for % of Total ( or the Percent_market_share) and it seemed to work on my end when pulling into a donut chart as a tooltip to hover on. 
Things that you can check on your end: 
Your source page and tooltip page has the button: Keep all filters - turned on. 

Your tooltip page can be formatted as a tooltip page by going into the format settings and changing the type of page in 'Canvas settings' to 'Tooltip'. Refer screenshot: 

dhruvinushah_0-1654031372777.png

 

This is how my page 2 or the Tooltip page looks: 

dhruvinushah_1-1654031412471.png

And this is how the tooltip hover for the total works on my end: 

dhruvinushah_2-1654031550078.png

 

If the above checks don't work try this for your % of category share calculation : 

Percent Total = 
var A2 = DIVIDE( SUM(Sales[SalesAmount]), CALCULATE(
	SUM('Sales'[SalesAmount]),
	ALL('ProductCategory'[ProductCategory])
))

RETURN
A2


Hope this helps answer your question. 




-- 1st Reply:
Without actually being able to see the measure calculation it's difficult to assume the context of the calculation involved in the report tooltip used by your measure and donut chart. 
My best guess regarding the incorrect numbers would be that your measure is calculating the values in a diffferent context. The "Keep Filters" on switch will push other filters you have on your donut chart page to apply on the tooltip as well. Check if the denominator fields are being affected by any filters you applied on the donut chart page. 

-- End

Hope this helps, tag me (@) if you need more help on it. Feel free to mark the answer as a solution if it helped you.
Thanks!









Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.