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
noliverte
Helper III
Helper III

graphic filtering : formula problem

Hello,

I have the following  reporting test

screen1.PNG

On the top left, I have a filter (with all my campaigns name)

When I select one campaign, I'd like to have "note_20" in the red field (as in the table), but I have a wrong result

 

For instance when I select campaign2, I have the following result

screen2.PNG

instead of 17,79...

 

My formula

- note_20 = DIVIDE(Feuil1[total_score]*20,[Maximum de score par campaign_name])

screen3.PNG

 

 

total_score = sum(Feuil1[score])

screen4.PNG

Maximum de score par campaign_name =
MAXX(ALLSELECTED(Feuil1[campaign_name]),[total_score])

screen5.PNG

Question : How can I display the right "note_20" value in the red field ?

 

A response would be appreciated.

 

Have a nice day

 

Noliverte

1 ACCEPTED SOLUTION
mahoneypat
Employee
Employee

Your measure is always going to return 20, since you are basically multiplying 20 by 1 (when one campaign is selected).  Switch your ALLSELECTED to an ALL to get the correct result (in your existing measure or in a new measure just for that card).

 

If this works for you, please mark it as the solution.  Kudos are appreciated too.  Please let me know if not.

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


View solution in original post

5 REPLIES 5
simrantuli
Continued Contributor
Continued Contributor

Hi @noliverte ,

 

Can you share the pbix?

 

Thanks

Simran Tuli

mahoneypat
Employee
Employee

Your measure is always going to return 20, since you are basically multiplying 20 by 1 (when one campaign is selected).  Switch your ALLSELECTED to an ALL to get the correct result (in your existing measure or in a new measure just for that card).

 

If this works for you, please mark it as the solution.  Kudos are appreciated too.  Please let me know if not.

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


Thank you very very much, it works perfectly

mahoneypat
Employee
Employee

Since you slicer selection does not look to be filtering your two table visuals, is it also not filtering the card?  Turn on Edit Interactions with the slicer selected, and confirm it is filtering the card.

 

https://docs.microsoft.com/en-us/power-bi/create-reports/service-reports-visual-interactions

 

If this works for you, please mark it as the solution.  Kudos are appreciated too.  Please let me know if not.

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


Hello mahoneypat,

Thank you for your response.

My slicer is filtering just "note_20" (in red). It's what I want, but the result is always 20,00 (if I select a campaign0 or campaign1 or campaing2) and 55,75 if I have no selection in my slicer selection...

It's certainly a formula error ???

 

 

 

screen6.PNG

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.