I have a table COUNTRIES. I want a particular country to be displayed on the top and the rest of the countries to be displayed alphabetically. For example my expectation is :
India -- to be displayed always on top Afghanistan Bulgaria Canada Denmark Zambia
答案 0 :(得分:0)
You can do this by putting conditional expressions in the order by
:
order by (case when countryname = 'India' then 1 else 2 end),
countryname