Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

mysql order specific records at the top

SELECT id, name, grade
FROM Students
ORDER BY FIELD(grade, "A") DESC, name ASC;
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #mysql #order #specific #records #top
ADD COMMENT
Topic
Name
1+6 =