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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
as19
Frequent Visitor

Sum cards with different filters applied

I am creating a calculator/planner

I have a page sectioned off into 4 areas, each area has 4 KPI cards which hold a measure value, which are filtered by thier respective slicers.The slicers only filter their respective sections.
The measures in the cards are all different:

 

Section 1 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

 

I would like to have cards below which sum up the value of that column. For example:

 

Section 1 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

Section 2 - (Slicers) Card1, Card 2, Card 3, Card 4

     Sum of Card1s, Sum of Card2s, Sum of Card3s, Sum of Card 4s

 

When i do this i get a blank for the sums. 

Is there a way to do this?

9 REPLIES 9
CH8
New Member

Did u already find any solution, since I'm getting the same problem. Suprisingly, I want to make a same kind of planner for the club so that we can see the load of a session but could only see the values seperately and not the total sum of the load. Hopefully you found an answer to this! Please let me know! Thanks.

as19
Frequent Visitor

Hi,

 

Has anyone found or know of a solution for this? 

Really desperate to find an answer.

 

Thanks.

v-frfei-msft
Community Support
Community Support

Hi @as19 ,

 

I have created a sample for your reference. Please have a check. Please note here I have created four what if parameters.

card1 = AVERAGE('Table'[value])*Parameter[Parameter Value]
card2 = AVERAGE('Table'[value])*'Parameter 2'[Parameter Value 2]
card3 = AVERAGE('Table'[value])*'Parameter 3'[Parameter Value 3]
card 4 = 'Parameter 4'[Parameter Value 4]*AVERAGE('Table'[value])
sum = [card1]+[card2]+[card3]+[card 4]

 Capture.PNG

 

If it doesn't meet your requirement, Kindly share your sample data and excepted result to me if you don't have any Confidential Information. Please upload your files to One Drive and share the link here.

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Power Bi Issue.jpg

 

 

 

 

 

 

 

@v-frfei-msft @amitchandak @parry2k 

This approach doesnt work as each row of cards have thier own slicers applied to it. Therefore it returns blanks.

Hope the image above helps understanding.

Hard problem. @_@.

 

Maybe, as you have 4 sections, you could duplicate 4x times all the dimensions you have on the dashboard. Each section should have slicers from those duplicate dimensions, 1 or more for each section with all the exclusive dimensions for that 1 section. 

 

Important: All those duplicated dimensions should not have relationships with the fact tables, then you would need to adequate all the section measures with similar measures as i suggested for measure test.

 

After that you could make 1 measure that sum the aggregation of the 4 cards results.

 

 

 

measure test = 
var slicerA_dim1_name1 = values(dim1_name1[column])
var slicerB_dim1_name2 = values(dim1_name2[column])
var slicerN_dim1_nameN = values(dim1_nameN[column]) //N more as you need
var result_section1 = 
	calculate( 
		[my measure], 
		fact_table([column_name1]) in slicerA_dim1_name1, 
		fact_table([column_name2]) in slicerB_dim1_name2 , 
		fact_table([column_nameN]) in slicerN_dim1_nameN )
// same for other sections
return
	result_section1 //+ result_section2 + result_section3 + result_section4

 

 

 

amitchandak
Super User
Super User

The information you have provided is not making the problem clear to me. Can you please explain with an example. If possible please share a sample pbix file after removing sensitive information.

 

In case this is issue because the filter of one region filtering others. use edit interactions

 

Interactions.png

My Recent Blog -

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...

@amitchandak  - Please find my latest reply with screenshot for more information on my problem. Hopefuly this is more clear.

 

Thanks

parry2k
Super User
Super User

@as19 can you share what those measures are that you are using on card visuals? Can you share some screen shot and data example. Read this post to get your answer quickly.

https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

as19
Frequent Visitor

Image of Sections 

Each section has its own slicers to the left which i havent shown, which are only connected to the respective section row.

 

Here is the measure for Total Distance in section1 :

 
 

Drill1Distance = average(distance) * Drill1Duration Value

 

This will then be replicated in section 2, but replacing Drill1 with Drill2.

The 'Drill1Duration Value' is a whatif value i created and is dependent on the slicer value (the number in the drill duration box).

 

I would like cards underneath with a sum of the columns, so a sum of total distances.

 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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