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! Learn more

Reply
Anonymous
Not applicable

15 shift back

 

Untitled.png

hello i have date from that i want to calculate current shift like system date is 4/3/2018 2:47pm is current time and then find out that shift from
Shift Timing
=================
Shift A: 6AM to 2PM
Shift B: 2PM to 10PM
Shift C: 10PM to 6AM

how to find that shift means current shift,current shift-1,current shift -3.......up to 15th shift....,,,,
suggest some way....

1 ACCEPTED SOLUTION
stefans2403
Frequent Visitor

You need to calculate start time of current shift using GETDATE() and IF statement.

 

From there, it's easy to calculate shift order using start time of current shift -8 hours,-16 hours,-24 hours, etc. again using IF statement.

View solution in original post

2 REPLIES 2
stefans2403
Frequent Visitor

You need to calculate start time of current shift using GETDATE() and IF statement.

 

From there, it's easy to calculate shift order using start time of current shift -8 hours,-16 hours,-24 hours, etc. again using IF statement.

Anonymous
Not applicable

Hiii,


Can u explain more!!

 

Regards ,
Pooja

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