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
cbruhn42
Helper III
Helper III

Moving Range Using Date Time Column

I have a data set that looks like the following:

 

Date TimeLabelAttributeValueIndex
1/1/23 5:00amA1341
1/1/23 5:00amA2122
1/1/23 5:00amA3893
1/1/23 5:05amB1234
1/1/23 5:05amB2115
1/1/23 5:05amB3906
1/1/23 5:10amC1337
1/1/23 5:10amC2238
1/1/23 5:10amC3999
1/2/23 7:00amA13410
1/2/23 7:00amA21211
1/2/23 7:00amA38912

 

What I want to do is calculate a moving range for each Attribute by Label.  So in my example you can see that if I want to calculate for Lable A, Attribue 3 I can't use the Index -1 formula.  I also can't sort just by attribute then add an index column because the Labels will be in the wrong order and vice versa.

 

I am wondering how I can use the Date Time column to help resolve this, but can't figure it out.

 

Thanks.

1 REPLY 1
danextian
Super User
Super User

Hi @cbruhn42 ,

 

You didn't mention how to calculate for the moving range. What is your expected result?





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

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


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

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