UNION allows you to create a RESULTSETwith same type data from different SELECT statement.

The RESULTSET is generated with the column name of leading(first) SELECT statement.

For other SELECT statement columns data type should be matched according to the leading(first) SELECT statement.

For ORDERing, its applied on the RESULTSET, consequently in case of UNION, it only allows ORDER BY at the last SELECT statement but takes column name according to leading(first) SELECT statement, so below example is true:

Finally, since in the RESULTSET for UNIONing with different tables/sources aggregates all data into a column(according to first(leading) SELECT statement), so you can not apply ASC and DESC for same column.

Right

SELECT a FROM xxx
UNION
SELECT f FROM yyy
UNION
SELECT t FROM zzz order by a asc

Wrong: according to you

SELECT a FROM xxx
UNION
SELECT f FROM yyy
UNION
SELECT t FROM zzz order by a asc, a desc