MySql查詢結果按照指定順序排序

select * from news where id=2 or id=5 or id=1 order by find_in_set(id,'2,5,1'); select * from news where id in(3,1,5) order by substring_index('3,1,2',id,1); FIND_IN_SET(str,strlist)  假如字符串str 在由N 子鏈組
相關文章
相關標籤/搜索