
My actual requirement is getting my desired row on top and having my specific order. order by gives either Ascending or Descending. But i want a Custom way to have my Defined Order..
For that after googling it i got it....
//Creating a table called #temp
create table #temp( id int primary key,Pref_Score varchar(30)unique)
//and inserting it in the order i require
insert into #temp values(1,'Exceptional')
insert into #temp values(2,'Developing')
insert into #temp values(3,'Strong')
insert into #temp values(4,'Solid')
insert into #temp values(5,'UnAcceptable')
//and then selecting it ..
Select * from #temp order by id
Previously my problem is Even though i insert in the order i require SQL server automatically Sorting it...
So to stop and place my own order i declared a ID column and accessed the values from it....
Thanq Saravanan and RamKumar for your help.
Thanks,
Radha Srikanth
Chvrsri, if this helps please login to Mark As Answer. | Alert Moderator