Posted
Filed under 프로그래밍
http://www.mysqlkorea.com/sub.html?mcode=manual&scode=01&m_no=21703&cat1=12&cat2=353&cat3=0&lang=k

응용이 가능하다.


SELECT * FROM `test` order by case 
    when fileName LIKE "video%" then 1 
    when fileName LIKE "scene%"  then 2 
    else 3 
END


SELECT * FROM ORDER BY FIELD(a,3,4,5)

SELECT * FROM ORDER BY RAND()








2015/06/10 11:59 2015/06/10 11:59