Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

Group shifts

Hello,

 

I have two shifts: morning and night.

Lets consider 6/16/2020 and 6/17/2020 as the two dates and I will use the "Day" as my x-axis.

Morning shift starts 07:00 and ends 18:59.

Night shift starts 19:00 and ends 06:59.

 

The issue that I have is sense night shift runs into the 17th, it shows up on the 17th on the x-axis.

How do I stack my comlumns to show morning and night shifts of different days on the same x-axis mark?

 

Heres a picture of my dashboard

 

 

My "Day" is a calculated column:

Day = DAY('20200215143248'[offload])     

 

and my "Shift" is also a calcualted column"

Shift = IF(AND('20200615143248'[Hour] > 6, '20200615143248'[Hour] < 19), "Morning", "Night").

 

I am open to all suggestions and please let me know if I can be more clear.

Thanks!

 

4 Replies

  • Anonymous 

     

    Is this because the time slicer you are using contians 6/17?

    • Anonymous's avatar
      Anonymous
      Not applicable

      My date slicer does contain 6/17.

      I have to somehow group 6/17 19:00 - 06:59 to show on 6/16 date axis

      • vanessafvg's avatar
        vanessafvg
        Icon for Community Champion rankCommunity Champion
        you need to create a date table, set the and have 2 dates, one to slice on which is the date you want to user to see the date as, and then the date to do the calculations on. Does that make sense

        so in your date table

        date datetime
        2020-06-16 2012-06-17 19:01 will have a record for eat time under the date to use then you slice by that date or you can create a calculated column with an if statement that if its = this then the date should be this and slice on that date