Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
calvinkwoo3000
Yak Posting Veteran
98 Posts |
Posted - 2011-12-15 : 02:45:55
|
| My tableID Description 1 NULL2 DHL3 FEDEX4 UPS5 OTHER6 TNThow do i select and make the OTHER sort in the last position? |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2011-12-15 : 02:50:05
|
[code]ORDER BY case when [Description] = 'OTHER' then 2 else 1 end, ID[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
calvinkwoo3000
Yak Posting Veteran
98 Posts |
Posted - 2011-12-15 : 04:06:15
|
quote: Originally posted by khtan
ORDER BY case when [Description] = 'OTHER' then 2 else 1 end, ID KH[spoiler]Time is always against us[/spoiler]
Bravo, thank you so much khtan....this is what i want and you are very helpful...Thank you and thank for SQLteam.com and the master here.... |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2011-12-15 : 08:05:44
|
welcome KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
|
|
|