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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

sum a measure with parameter

Hello PowerBi Community

 

have a table of this kind :

FactoryDateResultLimit
A01/01/20201.381.5
B01/01/20201.751.5
A01/02/20201.851.7
B01/02/20201.521.7

 

I have a what if parameter to change the value of the limits. (By multiplicate the limits by the parameter)

Measure1 = sum(Table[Limit])*Parameter[Parameter value]

 

Then i have an another measure to calculate if the factory result is over the new limit :

Measure2 = [Measure1]-ABS(SUM(Table[Result]))
 

I want to count the number of sites that are over the limit

Measure3 = if([Mesure2]<0,1,0)
 

And now this is my problem i want to sum the Measure3 to know how many factory are over the limit. 
And use it in a graph with the date in x axis. 

 

Thank you for your help 🙂

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , try like

sumx(summarize(Table,Table[factory], "_1",[Measure3]),[_1])

sumx(filter(summarize(Table,Table[factory], "_1",[Measure3]),[_1]=1),[_1])

 

or

sumx(filter(summarize(Table,Table[factory], "_1",[Measure3]),[_1]=0),[_1])

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , try like

sumx(summarize(Table,Table[factory], "_1",[Measure3]),[_1])

sumx(filter(summarize(Table,Table[factory], "_1",[Measure3]),[_1]=1),[_1])

 

or

sumx(filter(summarize(Table,Table[factory], "_1",[Measure3]),[_1]=0),[_1])

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

This one perfectly works for me : 

sumx(filter(summarize(Table,Table[factory], "_1",[Measure3]),[_1]=1),[_1])

 

Thank you !

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.