Hi,
I'm trying to get the 400 most recently added records in a table but I want them ordered alphabetically rather than by their id number. I tried a secondary field in the order by statement but it made no difference. Here's what I tried:
SELECT id, name FROM people ORDER BY id DESC, name ASC LIMIT 400;
However this didn't work, it correctly selects the most recent 400 but still orders them by their id number not name. I'm guessing I'm missing something extremely simple but after a search on the internet and here I couldn't find the solution so thought I'd ask to see if anyone could help.
Thanks