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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
sraj
Responsive Resident
Responsive Resident

Aging bucket trying to add few more days

Hi,
 
I have this aging bucket measure, works fine as it is but when trying to add 120 days and above I am getting this error message.  Is it possible for me to add this 120 days and above option?  Please advise.
 
sraj_0-1677772809058.png

Aging Bucket =

VAR DaysAge =
    DATEDIFF ( uv_pbi_ar_pro_status_dtl[wf_task_open_dt], TODAY(), DAY )
RETURN
    SWITCH (
        TRUE (),
        DaysAge < 15, "Less than 15 days",
        DaysAge <= 30, "15-30 days",
        DaysAge <= 60, "30-60 days", "60 days and above"
                 )
1 ACCEPTED SOLUTION
sraj
Responsive Resident
Responsive Resident

I ended up using this and it works as needed for me.  

 

Aging Bucket 2 =
VAR DaysOld =
    DATEDIFF ( uv_pbi_ar_pro_status_dtl[wf_task_open_dt], TODAY(), DAY )
RETURN
    SWITCH (
        TRUE (),
        --or(ISBLANK(DaysOld),DaysOld <= 0), "Overdue",
        DaysOld <= 15, "0-15 Days",
        DaysOld > 15 && DaysOld <= 30 , "15-30 Days",
        DaysOld > 30 && DaysOld <= 60 , "30-60 Days",
        DaysOld > 60 && DaysOld <= 120 , "60-120 Days",
        DaysOld > 120, "120 Days Above"
        )

View solution in original post

2 REPLIES 2
sraj
Responsive Resident
Responsive Resident

I ended up using this and it works as needed for me.  

 

Aging Bucket 2 =
VAR DaysOld =
    DATEDIFF ( uv_pbi_ar_pro_status_dtl[wf_task_open_dt], TODAY(), DAY )
RETURN
    SWITCH (
        TRUE (),
        --or(ISBLANK(DaysOld),DaysOld <= 0), "Overdue",
        DaysOld <= 15, "0-15 Days",
        DaysOld > 15 && DaysOld <= 30 , "15-30 Days",
        DaysOld > 30 && DaysOld <= 60 , "30-60 Days",
        DaysOld > 60 && DaysOld <= 120 , "60-120 Days",
        DaysOld > 120, "120 Days Above"
        )
YukiK
Impactful Individual
Impactful Individual

Would you provide sample data? Formula looks fine to me

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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
Top Kudoed Authors