Forum Discussion

Davykyndt's avatar
Davykyndt
Frequent Visitor
8 years ago
Solved

Creat column with shift numbers

I have a calendar table where I'd like to add a column with workingshifts. I have 2 working shifts working 7 days for shift A and then 7 days for shift B.

 

Any idea how I can calculate this basen on my Senshiftday?

  • Hi I found a solution:

     

    Shiftnr = if((mod(calender[Date]+2;14)+1)<=7;"Shift A"; "Shift B")

     

     

5 Replies

  • Is there any relationship between SenShiftDay column and date column in your example?

    • Davykyndt's avatar
      Davykyndt
      Frequent Visitor

      No, this table is created from a calendarauto() function (Date column).

      • parry2k's avatar
        parry2k
        Super User

        how di d you calcualted senshiftday in your example? What made you choose value 1 to 7