mysql - Order by with more than 1 of lenght -
i'm getting weird results query:
select id, nivel, tipo, titulo, texto, ativa quests_faq order nivel asc;
the result should this:
5 10 15 20 40 50 55 etc..
instead, sorting first number:
10 15 2 30 40 5 55 etc
my row "nivel" contains integers.
how can use order in case purpose want?
this query may looking converting nivel number
select id, nivel, tipo, titulo, texto, ativa quests_faq order convert( nivel, integer) asc
Comments
Post a Comment