SQL query order execution select * from employee group by department order by empid desc 1] From 2] Where 3] Group by 4] Having 5] Select 6] Distinct 6] Order by 7] Limit