Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi I need help with the following calculation:
Based on the table below, I need to calculate the cummulative sum for each salesman based on the date as it shows in the "CummulativeRunRate" coulmn. A start date needs to be define and the numbers of days of the fiscal month. Also create the Delta column.
thanks,
Reggie
Solved! Go to Solution.
How do you want to create your fiscal calendar?
I assume you already have a Calendar date in your table, then you can create a fiscal month column like:
Fiscal Month = IF(MONTH('Table'[Date])-MONTH(NOW())<=0,MONTH(NOW())-MONTH('Table'[Date])+1,MONTH(NOW())-MONTH('Table'[Date])+13)
Then generate a Fiscal Year column like:
Fiscal Year =
IF (
Table[Fiscal Month] < MONTH ( Table[Date] ),
YEAR ( Table[Date] ),
YEAR ( Table[Date] ) + 1
)
You can still keep the Day part from Calendar Date.
To calculate the cumulative date, you can create column like below:
Cumulative Total =
CALCULATE (
SUM ( Table[Sales] ),
FILTER (
Table,
Table[Fiscal Year] = EARLIER ( Table[Fiscal Year] )
&& Table[Fiscal Month] = EARLIER ( Table[Fiscal Month] )
&& Table[Day] <= EARLIER ( Table[Day] )
&& Table[SalesMan] = EARLIER ( Table[SalesMan] )
)
)
Regards,
How do you want to create your fiscal calendar?
I assume you already have a Calendar date in your table, then you can create a fiscal month column like:
Fiscal Month = IF(MONTH('Table'[Date])-MONTH(NOW())<=0,MONTH(NOW())-MONTH('Table'[Date])+1,MONTH(NOW())-MONTH('Table'[Date])+13)
Then generate a Fiscal Year column like:
Fiscal Year =
IF (
Table[Fiscal Month] < MONTH ( Table[Date] ),
YEAR ( Table[Date] ),
YEAR ( Table[Date] ) + 1
)
You can still keep the Day part from Calendar Date.
To calculate the cumulative date, you can create column like below:
Cumulative Total =
CALCULATE (
SUM ( Table[Sales] ),
FILTER (
Table,
Table[Fiscal Year] = EARLIER ( Table[Fiscal Year] )
&& Table[Fiscal Month] = EARLIER ( Table[Fiscal Month] )
&& Table[Day] <= EARLIER ( Table[Day] )
&& Table[SalesMan] = EARLIER ( Table[SalesMan] )
)
)
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.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 56 | |
| 40 | |
| 36 | |
| 20 | |
| 18 |
| User | Count |
|---|---|
| 74 | |
| 72 | |
| 38 | |
| 35 | |
| 26 |