Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I have attach a screenshot of my table view :http://prntscr.com/jx6ow8
I have created a measure :
Measure 6 = CALCULATE(COUNT(TblStudent[StId]),TblStudent[StStatus]="Active"), which give count of active student,
I have created another measure:
StudentCount=IF(CALCULATE(COUNT(TblStudent[StId]),TblStudent[StStatus]="Active")>20,20,CALCULATE(COUNT(TblStudent[StId]),TblStudent[StStatus]="Active"))
It return 20 if count of student is greater than 20 in table view else same value, But the total at bottom in table show 20 for StudentCount, please guide how can I correct it?
Thanks in advance...
HI @mohit19,
You can try this, I add condition to skip replace formula calculate on total level:
StudentCount =
IF (
CALCULATE ( COUNT ( TblStudent[StId] ), TblStudent[StStatus] = "Active" )
> 20
&& ISFILTERED ( TblStudent[StId] ),
20,
CALCULATE ( COUNT ( TblStudent[StId] ), TblStudent[StStatus] = "Active" )
)
Regards,
Xiaoxin Sheng
Seems like a classic case that https://community.powerbi.com/t5/DAX-Commands-and-Tips/Dealing-with-Measure-Totals/m-p/63376#U63376 will solve
It does not solve my problem, can you please provide dax expression for that.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 132 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |