SELECT carrier, id,
FROM flights f
WHERE f.id < flights.id
AND f.carrier=flights.carrier) + 1
This is the code from the example they gave us, I don't understand what f is, is it just an alias for flights, and if so whats the point of f.id < flights.id, and what is the point of the +1?