尽管GROUP,ORDER和其他参数如何将一个选择结果行移到顶部? 例如SqlFiddle
将第3行(类型为Loren)移至顶部?
答案 0 :(得分:1)
select id, type, details from dummyTable order by type="Lorem" DESC
答案 1 :(得分:1)
答案是
select id, type, details from dummyTable ORDER BY IF(type = 'Test', 0, 1), id LIMIT 0, 5