SQL の ORDER BY

SELECT a, MAX(a) AS max_a FROM hoge ORDER BY max_a;


  と

SELECT a, MAX(a) FROM hoge ORDER BY 2;


  は同義.
  Oracle,MySQL で確認