Don't miss your chance to take the Fabric Data Engineer (DP-600) exam for FREE! Find out how by attending the DP-600 session on April 23rd (pacific time), live or on-demand.
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hi all,
I figured out a formula to calculate the cumulative of new and closed orders.
It seems to work, but when I calculate myself, it is off.
So the month of January 755 cumulative is correct, but the month of February should be 1327, not 1426
This happens because the filter for the terminal isn't working. Can anyone tell me what I need to change in my formula?
Solved! Go to Solution.
Hi @IAM ,
Please update the formula of measure [Cumulative] as below and check whether that can return the correct result...
| Cumulative = CALCULATE ( SUM ( 'Calculate1'[NewWorkorders] ), FILTER ( ALL ( 'Calculate1' ), 'Calculate1'[First day] <= EARLIER ( 'Calculate1'[First day] ) && 'Calculate1'[Terminal] = EARLIER ( Calculate1[Terminal] ) ) ) - CALCULATE ( SUM ( 'Calculate1'[closedWorkorders] ), FILTER ( ALL ( 'Calculate1' ), 'Calculate1'[First day] <= EARLIER ( 'Calculate1'[First day] ) && 'Calculate1'[Terminal] = EARLIER ( Calculate1[Terminal] ) ) ) |
If the above one can't help you get the desired result, please provide some sample data in Calculate1 table (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.
How to upload PBI in Community
Best Regards
@IAM , the Number is correct as per your formula, Can share the logic ?
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
Sadly I cannot share this..
The problem is the red part of the formula. It isn't using this part of the filter.
It should filter out only the terminal as the name of the terminal that is on that row.
Hi @IAM ,
Please update the formula of measure [Cumulative] as below and check whether that can return the correct result...
| Cumulative = CALCULATE ( SUM ( 'Calculate1'[NewWorkorders] ), FILTER ( ALL ( 'Calculate1' ), 'Calculate1'[First day] <= EARLIER ( 'Calculate1'[First day] ) && 'Calculate1'[Terminal] = EARLIER ( Calculate1[Terminal] ) ) ) - CALCULATE ( SUM ( 'Calculate1'[closedWorkorders] ), FILTER ( ALL ( 'Calculate1' ), 'Calculate1'[First day] <= EARLIER ( 'Calculate1'[First day] ) && 'Calculate1'[Terminal] = EARLIER ( Calculate1[Terminal] ) ) ) |
If the above one can't help you get the desired result, please provide some sample data in Calculate1 table (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.
How to upload PBI in Community
Best Regards
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.
| User | Count |
|---|---|
| 48 | |
| 40 | |
| 37 | |
| 20 | |
| 15 |
| User | Count |
|---|---|
| 70 | |
| 67 | |
| 32 | |
| 27 | |
| 25 |