Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Cumulative total per category and date presented in matrix

Hello,

I would like to create a visualization which shows cumulative totals of leads per week/month/year (it's a hierarchy) and per leads stage.

 

In columns I have snapshot dates, but in rows leads stages. what formula should I create?

I used:

Contacts = CALCULATE('Reporting HubSpotContactDataSnapshotView'[Contacts No],

FILTER(ALLEXCEPT('Reporting HubSpotContactDataSnapshotView','Reporting HubSpotContactDataSnapshotView'[lifecyclestage]),'Reporting HubSpotContactDataSnapshotView'[Week]<=max('Reporting HubSpotContactDataSnapshotView'[Week])))
but I'm not sue it is correct as I have some 'blank values' . For me it shouldn't have happend as it is cumulative value.
it96_0-1632222212438.png
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi  @Anonymous ,

You try to modify the formula to the following form:

Contacts = 
CALCULATE('Reporting HubSpotContactDataSnapshotView'[Contacts No],
FILTER(All('Reporting HubSpotContactDataSnapshotView),[lifecyclestage]=MAX([lifecyclestage] &&
'Reporting HubSpotContactDataSnapshotView'[Week]<=max('Reporting HubSpotContactDataSnapshotView'[Week])))

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi  @Anonymous ,

You try to modify the formula to the following form:

Contacts = 
CALCULATE('Reporting HubSpotContactDataSnapshotView'[Contacts No],
FILTER(All('Reporting HubSpotContactDataSnapshotView),[lifecyclestage]=MAX([lifecyclestage] &&
'Reporting HubSpotContactDataSnapshotView'[Week]<=max('Reporting HubSpotContactDataSnapshotView'[Week])))

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Anonymous
Not applicable

Thank you for your help! I'm afraid the suggested solution does not work, but please find the link to the data and expected outcome.

 

https://docs.google.com/spreadsheets/d/1q6ECnYvXJGbPHTpL5Ot4Q1eUeRhw8NH1/edit?usp=sharing&ouid=11326... 

 

Really appreciate that 🙂

amitchandak
Super User
Super User

@Anonymous ,Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

 

Best way is to have week or date table and try like

 

Contacts = CALCULATE('Reporting HubSpotContactDataSnapshotView'[Contacts No],ALLEXCEPT('Reporting HubSpotContactDataSnapshotView','Reporting HubSpotContactDataSnapshotView'[lifecyclestage])
FILTER(allselected('Week'),'Week'[Week]<=max('Week'[Week])))

 

and use week from this table in visual

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors