Can someone explain why this if statement is not working?
If DateDiff ("s", {incident_log.sched_time},{incident_log.incident_date_time} ) < -30 then "Early" else
If DateDiff ("s", {incident_log.sched_time},{incident_log.incident_date_time} ) > 330 then "Late" else
else "OnTime"
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*SOUTH*" and {incident_log.tp_id} = 12790
then "OnTime" else
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*NORTH*" and {incident_log.tp_id} = 12782
then "OnTime"
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*NORTH*" and {incident_log.tp_id} = 12763
then "OnTime
If DateDiff ("s", {incident_log.sched_time},{incident_log.incident_date_time} ) < -30 then "Early" else
If DateDiff ("s", {incident_log.sched_time},{incident_log.incident_date_time} ) > 330 then "Late" else
else "OnTime"
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*SOUTH*" and {incident_log.tp_id} = 12790
then "OnTime" else
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*NORTH*" and {incident_log.tp_id} = 12782
then "OnTime"
If {incident_log.current_route_id} = 103 and {direction_codes.direction_description} like "*NORTH*" and {incident_log.tp_id} = 12763
then "OnTime