Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I want to display a summary of employees who worked more than 61 hours per week in a straight table.
Below shows the details of employees.
I got worked hours using following query on the expression.
=if((Num#(Sum(if((Week(makedate(year(IN_DATE),month(IN_DATE),day(IN_DATE)))=Week(makedate(year(vMinDate),month(vMinDate),day(vMinDate)))),Interval(CHECK_OUTTIME-CHECK_INTIME,'hh'))))>=61)
=-1,Sum(if((Week(makedate(year(IN_DATE),month(IN_DATE),day(IN_DATE)))=Week(makedate(year(vMinDate),month(vMinDate),day(vMinDate)))),Interval(CHECK_OUTTIME-CHECK_INTIME,'hh'))))
But when i try to get the summary in another straight table it doesn't show as i expected. The expected results show as below.
I tried following query, can anyone please tell me what did i do wrong and how to get the correct count.
if((Num#(Sum(if((Week(makedate(year(IN_DATE),month(IN_DATE),day(IN_DATE)))=Week(makedate(year(vMinDate),month(vMinDate),day(vMinDate)))),Interval(CHECK_OUTTIME-CHECK_INTIME,'hh'))))>=61)
=-1,Count(DISTINCT EMPLOYEE_ID))
Thank You
You can also try this
Count(DISTINCT
{<
[Employee Id] = {"=Num#(Sum(If(Week(IN_DATE) = Week(vMinDate), Interval(CHECK_OUTTIME - CHECK_INTIME, 'hh')))) >= 61"}
>}
[Employee Id])
sum(if((Num#(Sum(if((Week(makedate(year(IN_DATE),month(IN_DATE),day(IN_DATE)))=Week(makedate(year(vMinDate),month(vMinDate),day(vMinDate)))),Interval(CHECK_OUTTIME-CHECK_INTIME,'hh'))))>=61) =-1,1,0))
You can also try this
Count(DISTINCT
{<
[Employee Id] = {"=Num#(Sum(If(Week(IN_DATE) = Week(vMinDate), Interval(CHECK_OUTTIME - CHECK_INTIME, 'hh')))) >= 61"}
>}
[Employee Id])
Thank you for helping me out. Really appreciate your support!!