I need help with the following code:
SELECT ID, (CASE WHEN SUM(ArrivalsDelay) > SUM(DeparturesDelay) THEN ArrivalsDelay WHEN SUM(ArrivalsDelay) < SUM(De