I'm trying to get a percentage of less than 10 mints, in dataset I have values where start time is before the arrival time and instead of counting them as negative it displaying positive, how Can I fix this.
SUM((CASE
WHEN (TIME_TO_SEC(timeDIFF(`Start Time (UTC)`, `Arrival Time (UTC)`)) / 60) <=10 THEN 1
END))
/
SUM((CASE WHEN `Case Number` is not null then 1
end))