Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Dear,
I have the following table:
Where I'd like to create a column with the cumulative sum of the "YTD_Actuals_per_project" in fuction of specific rows for "Project_Act" (Marked in yellow)
Basically, I want to do a running sum for each new increment of "Project_Act", i.e for 1,2 and 3 .... And not taking duplicate.
Hope I was clear enough.
Thnaks in advance for your support.
Hi @rajendraongole1 , thanks for your code ! Really appreciate your help. The code is working fine but not getting what I'm expecting. I was not clear enough, my bad. Here below an excel screenshot of what I'd like to do:
Hi @Yazid ,
As you know Power BI data model doesn't recognize your yellow highlighting 😀, so you need to write the condition to apply in your YTD calculation. It appears in your data that in your Month field, "janvier 2024" numbers are highlighted except for the 1st item. Is there any logical pattern in your highlighting of the numbers? In that case, you need to convert that logic into the filter condition on which to apply your YTD calculation.
Best regards,
Hi @Yazid - can you try the below logic to create a dax calcualted column
Cumulative_Sum_YTD_Actuals_per_project =
VAR CurrentProject = YourTable[Project_Act]
RETURN
CALCULATE (
SUM ( YourTable[YTD_Actuals_per_project] ),
FILTER (
ALL ( YourTable ),
YourTable[Project_Act] = CurrentProject &&
YourTable[YTD_Actuals_per_project] <> BLANK ()
/* Add any other conditions if needed */
),
YourTable[Project_Act] <= CurrentProject
)
Once you create the above calculated column in your Power BI data model, it will calculate the cumulative sum of YTD_Actuals_per_project based on specific rows for the Project_Act
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!
Proud to be a Super User! | |
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.