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! Request now

Reply
billuran0912
New Member

Count number of days from past and future dates and then assign factor to sales number

Hello, I have a sales pipeline and I want to calcuate the age of the account from when it starts for each month of 2024. 

 

Sales table

AccountStartDateSales
abc2/5/2410000

Date Table

DateMonthYear
1/10/241/1/24

 

So for every month on a matrix table it will show the difference from the Startdate to the Date in the month. I want to then aggregate those sales numbers and say if the the age of each account is over 30 days multiply sales for each account by 50% if less then 30 multiply 10%. I have more buckets but can add those later. Hope this is clear

2 REPLIES 2
Anonymous
Not applicable

Hi @billuran0912 

 

Just as @ryan_mayu , I've read once and once again, I haven't understand what is your expected outcome.

But as your description, maybe datediff() function can help you.

Here for your reference:

DATEDIFF function (DAX) - DAX | Microsoft Learn

 

Best Regards

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

ryan_mayu
Super User
Super User

not clear about this. pls provide more sample data and the expected output.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




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