Skip to main content

I have a calculated field that calculates difference in hours from case date to last work date.

Below is my calculated field , I need to sum up hours differences where system down = 'Yes'.

in the below picture, I have 13.00 and 35.02, I need to have only total 48.02 on my view with system down 'Yes'

 

How can I get a sum of aggregated values with an IF function displayed on the view 

The below calculation returns a 0. The goal is to get a total of hour difference where system down = 'Yes'

 

WINDOW_SUM(IF ATTR([System down]= 'Yes')

THEN ABS((DATEDIFF('minute',MIN([Case date]),MAX([date])) / 60))

ELSE 0

END)

1 件の回答
  1. 2022年12月6日 16:15

    @Michael Madisha​ 

    Hi, you may use something like:

    {FIXED [Caseno]: IF MAX([System down])="Yes" THEN

    DATEDIFF('minute',MIN([Case date]),MAX([date]))/60 ELSE 0 END}

    @Michael Madisha​ Hi, you may use something like:{FIXED [Caseno]: IF MAX([System down])=If this post resolves the question, would you be so kind to "Select as Best"?. This will help other users find the same answer/resolution and help community keep track of answered questions. Thank you.

     

    Regards,

     

    Diego Martinez

    Tableau Visionary and Forums Ambassador

0/9000