Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hi @muchtamo ,
Could you tell me if your problem has been solved?
If it is, kindly Accept it as the solution. More people will benefit from it.
Or you are still confused about it, please provide me with more details about your table and your problem or share me with your pbix file from your Onedrive for Business.
Best Regards,
Stephen Tao
Hi @muchtamo ,
We usually use the SUMX function or the HASONEVALUE function to solve the problem of incorrect matrix Subtotals.
Try this
Total Actuals =
SUM ( 'dbprojects tbl_t_project_impact'[actual] )
Total Plan =
SUM ( 'dbprojects tbl_t_project_impact'[plan] )
Forecast1 =
IF (
[Total Actuals] = 0,
SUMX (
'dbprojects tbl_t_project_impact',
[Total Plan]
),
SUMX (
'dbprojects tbl_t_project_impact' ,
[Total Actuals]
)
)
Reference: DAX – Subtotals and Grand Totals That Add Up “Correctly”
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello @muchtamo ,
You would need to create 3 measures as follows:
Total Actuals =
CALCULATE ( SUM ( 'dbprojects tbl_t_project_impact'[actual] ) )
Total Plan =
CALCULATE ( SUM ( 'dbprojects tbl_t_project_impact'[plan] )
Total Monthly Forecast =
VAR ActualSum = [Total Actuals]
VAR PlanSum = [Total Plan]
RETURN
IF (
ActualSum = 0,
SUMX (
'dbprojects tbl_t_project_impact',
[Total Plan]
),
SUMX (
VALUES ( 'dbprojects tbl_t_project_impact' ),
[Total Actuals]
)
)
And then plot the last measure in the chart and see the results.
Please let me know if this didn't work.
User | Count |
---|---|
89 | |
85 | |
66 | |
62 | |
57 |
User | Count |
---|---|
138 | |
112 | |
94 | |
82 | |
71 |