cancel
Showing results for
Search instead for
Did you mean:
Super User II

Re: Total working hours / week

I understand! 🙂

I'm not quite sure if this works but check if you can toggle subtotals on column level,

Connect on LinkedIn
Helper IV

Re: Total working hours / week

Hi tex628,

I am really sorry but I keep on facing little issues with this one.

i have group the row to obtain total and I am wondering if I could only display the total and have something say P1 with the month above.

i have this option avaible and I thought the results was not matching the results of our new formua P1_S1 etc... Turns out that when I added the total with that new formula, the system also shows a total of 6 while the distinct count for the table shows 7 as well as the ID details.

Helper IV

Re: Total working hours / week

Hi tex628,

Just forgot about what I just said. It must be the return from holiday that is playing a trick on me.

It is fine. I have got the right results in both instance.

The only thing I can't figure out is that 5+hours being classified as 35hours +. It is one of those week that was falling into two periods.

Super User II

Re: Total working hours / week

Can you post the measure that you are currently using to calculate the hours?

Connect on LinkedIn
Helper IV

Re: Total working hours / week

Hi,

It is really weird what is happening. When I click on the count of ID for more than 35hours, ID 7173 shows up under this bracket but only display 5:40 hours. However, from another table, if I click on the same driver, the table updates and shows the correct amount.

My formula is

DifferenceDur = SUM(StartStop[LastActionDec]) - SUM(StartStop[FirstActionDec])

Decimal Hours (Hrs) = ([DifferenceDur])/60

Super User II

Re: Total working hours / week

And for the grouping? 🙂

Connect on LinkedIn
Helper IV

Re: Total working hours / week

Hi,

HOURLY BRACKETS = VAR DRIVER = DriverStartStop[Driver]
VAR WEEK = DriverStartStop[weeknum]
RETURN
IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)<20,"Less than 20hrs",IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)<=35,"Btw 20hrs & 35 hrs",IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)>35,"More than 35hrs")))

Super User II

Re: Total working hours / week

HOURLY BRACKETS = VAR DRIVER = DriverStartStop[Driver]
VAR WEEK = DriverStartStop[OUR NEW CREATED SUB-PERIOD]
RETURN
IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)<20,"Less than 20hrs",
IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)<=35,"Btw 20hrs & 35 hrs",
IF(CALCULATE(SUM(DriverStartStop[Decimal Hours Driver]), ALL(DriverStartStop), DriverStartStop[Driver]=DRIVER, DriverStartStop[weeknum]=WEEK)>35,"More than 35hrs")))

Instead of referencing the week we now want to reference the new sub period that we are using instead (P1_S1 ... P1_S2 ... and so on)

Connect on LinkedIn
Highlighted
Helper IV

Re: Total working hours / week

Hi,

Thank you so much for your help. It is all working fine now.

Super User II

Re: Total working hours / week

No worries! 🙂

Connect on LinkedIn

Helpful resources

Announcements

New Ranks Launched March 24th!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power BI Community!

‘Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Arun 'Triple A' Event Video, Q&A, and Slides

Missed the Arun 'Triple A' event or want to revisit it? We've got you covered! Check out the video, Q&A, and slides now.

Join THE global Power Platform event series.

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities.

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors