SELECT CASE WHEN (Id = 1) THEN 'aaa' WHEN (Id=2) THEN 'bb' WHEN(Id=3) THEN 'cc' END AS xx FROM table1 ORDER BY xx