sort the dates in the bank

0

I have the following problem, I can not sort in ascending order the dates that are saved in the bank, I am using the order by no select but only orders the first two houses until arriving in / making the month messy, my project is android but I believe that anyone who has knowledge with bank can help me, if anyone can thank

I currently made a table in the database just to test table schedule field date = date

with the bars (05/01/2016)

I already tried to register the date without the bars (05012016)

Without the 0 (512016)

without the 0 with the bars (5/1/2016)

and to sort select * from calendar order by date

    
asked by anonymous 17.10.2016 / 19:49

1 answer

0

Victor, try to use DESC in ORDER BY .

For decreasing:

select * from agenda order by  data desc;

For growing:

select * from agenda order by  data asc;
    
19.10.2016 / 14:27