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! Learn more
Date of creation column is there to do the calculation.
Please help me to do the same using Date Between, Date Add functions.
Please
Used the following formula, Insteasd of 90 days, I want to add month number
Instead of writing
New Customer in Last 3 Months New =
CALCULATE( DISTINCTCOUNT(Sales[CustomerCode]),
    DATESBETWEEN('Sales'[DateofOrder],
    TODAY()-90,
    TODAY()
    )
)you should use the Date table
New Customer in Last 3 Months New =
var __today = TODAY()
var __90DaysBackFromToday = TODAY() - 90 + 1 -- yes, you have to add 1
var output =
CALCULATE (
    DISTINCTCOUNT( Sales[CustomerCode] ),
    DATESBETWEEN (
        'Dates'[Date],
        __90DaysBackFromToday,
        __today
    )
)Best
Darek
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.
            | User | Count | 
|---|---|
| 8 | |
| 5 | |
| 5 | |
| 4 | |
| 3 | 
| User | Count | 
|---|---|
| 24 | |
| 11 | |
| 10 | |
| 9 | |
| 8 |