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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Generate a sequence for Orders each day

Hello! I need some help generating a sequence for orders that restarts each day. Currently I have a sequence column in my xlsx but it counts 1 to end of document. I would like the sequence to be based off of order times and restart each day. 

 

Example of current state:

 

SequenceDateOrderTime
1Feb 15A8:00
2Feb 15B8:01
3Feb 16C8:00
4Feb 17D8:00

 

Example of desired State:

 

SequenceDateOrderTime
1Feb 15A8:00
2Feb 15B8:01
1Feb 16C8:00
1Feb 17D8:00

 

Thanks!

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , Create a new column like

 

countx(filter(Table, [Date] = earlier([Date]) && [Order Time] <= earlier([Order Time]) ),[Order Time])

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
Anonymous
Not applicable

@amitchandak 

 

This is pretty close, 

 

This is what I put for the new column

Seq = COUNTX(FILTER(AMSformatted, [Prod Date] = EARLIER([Prod Date]) && [time_seq] <= EARLIER([time_seq])),[time_seq])
 
But it is counting by 2's in some areas
count by 2's.png

 

 and by 1 in other areas 
count by 1.png

 

 
 

 

Helpful resources

Announcements
November Fabric Update Carousel

Fabric Monthly Update - November 2025

Check out the November 2025 Fabric 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.

Users online (25)