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 all
I have a table for ticket purchases that looks like this...
Ticket sales for 2023 start on a different date than in 2024. In order to do a comparison, I've added week numbers for each year starting at the first date tickets were sold (formatted as dd/mm/yyyy). I need to be able to plot cumulative totals on a graph like below but haven't been successul in making it work. Could someone please help me create a measure that will do this? Thanks
Solved! Go to Solution.
You can use the following DAX measure to get the desired result:
Cumulative Count =
COUNTROWS (
FILTER (
ALL ( 'Table' ),
'Table'[Week] <= MAX ( 'Table'[Week] )
&& 'Table'[Year] = MAX ( 'Table'[Year] )
)
)
I have created the "Year" calculated column using the following DAX formula:
Year = YEAR('Table'[date])
Here is the solution screenshot in Power BI:
Best Regards,
Udit
If this post helps, please consider Accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudo 👍
🚀 Let's Connect: LinkedIn || YouTube || Medium || GitHub
✨ Visit My Linktree: LinkTree
Thanks quantumudit, that worked perfectly! I appreciate your help with this 🙂
You can use the following DAX measure to get the desired result:
Cumulative Count =
COUNTROWS (
FILTER (
ALL ( 'Table' ),
'Table'[Week] <= MAX ( 'Table'[Week] )
&& 'Table'[Year] = MAX ( 'Table'[Year] )
)
)
I have created the "Year" calculated column using the following DAX formula:
Year = YEAR('Table'[date])
Here is the solution screenshot in Power BI:
Best Regards,
Udit
If this post helps, please consider Accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudo 👍
🚀 Let's Connect: LinkedIn || YouTube || Medium || GitHub
✨ Visit My Linktree: LinkTree
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Ask questions in Eventhouse and KQL, Eventstream, and Reflex.
User | Count |
---|---|
71 | |
36 | |
21 | |
19 | |
15 |
User | Count |
---|---|
125 | |
37 | |
29 | |
29 | |
24 |