What is the meaning of "f", how to use?


#1

SELECT carrier,id,
(SELECT COUNT(*)
FROM flights f
WHERE f.id AND f.carrier=flights.carrier)+1 AS flight_sequence_number
FROM flights;

what the meaning of "f" in third line , i am confused.


#2

@pythonsolver82340,
Have a look at the discussion
http://stackoverflow.com/questions/4164653/whats-the-purpose-of-sql-keyword-as

You can also read
https://docs.oracle.com/cd/E17952_01/refman-5.0-en/select.html
and look at the definition of the table-reference


#3