Question : mysql procedure order by

Hi experts,
I have an urgent problem. i have  large table. I am trying to extract rows by a column named category and sort them by a numerical column in ascending order. I then want to insert these rows into  another table.
So I am using a procedure which fetches the set of category names and get rows for that cateogry and sorts them.
However the order by does not seem to work. It does not work in other in stored procedures.
I need to solve this right away. I would really appreciate any help on this
thanks

Answer : mysql procedure order by

Oops SORRY! My bad.

Heres a working example for MYSQL!


SELECT a.* FROM articles AS a
  LEFT JOIN articles AS a2  
   ON a.section = a2.section AND a.article_date <= a2.article_date
GROUP BY a.article_id
HAVING COUNT(*) <= 100;

Random Solutions  
 
programming4us programming4us