Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Heres the situation, according to my dataset(made one fast on Excel to speed things up) i need to retrieve the amount of students which the sum of values is equal to 0:
Heres the dataset:
Ive tried to create this measure :
Measure = CALCULATE(DISTINCTCOUNT(Table1[ID_Student]), FILTER((Table1, SUM((Table1[Value])=0))+0
But it always returning 0 instead of the expect result which is 2.
Solved! Go to Solution.
Okay, thank you. Try this:
Measure =
VAR __table = SUMMARIZE('Table','Table'[Student],"__sum0",SUM('Table'[Value]))
RETURN COUNTX(FILTER(__table,[__sum0]=0),[Student])
Proud to be a Super User!
Hi @BostonBI
please try
Measure1 =
SUMX (
VALUES ( Table1[ID_Student] ),
INT ( CALCULATE ( SUM ( Table1[Value] ) ) = 0 )
)
Hi @BostonBI
please try
Measure1 =
SUMX (
VALUES ( Table1[ID_Student] ),
INT ( CALCULATE ( SUM ( Table1[Value] ) ) = 0 )
)
Okay, thank you. Try this:
Measure =
VAR __table = SUMMARIZE('Table','Table'[Student],"__sum0",SUM('Table'[Value]))
RETURN COUNTX(FILTER(__table,[__sum0]=0),[Student])
Proud to be a Super User!
You got that Right,Thank you Alot!
Hi,
my solution:
Measure =
VAR __table =SUMMARIZE(FILTER('Table','Table'[Value]=0),'Table'[Student],"__count0",count('Table'[Subject]))
RETURN sumx(__table,[__count0])
Proud to be a Super User!
Theres actually 4 students on my example, Which 2 of them got only 0 In theis values. Summarizing:
I need to return the amount of students which all values Science,Math and English are 0.
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
22 | |
7 | |
6 | |
6 | |
6 |
User | Count |
---|---|
27 | |
10 | |
10 | |
9 | |
6 |