I’m having some problem in using order by in mysql. I have a table called “site” with 3 fields like id,name,rank. This table consists around 1.4m records. when i apply query like,
select name from site limit 50000,10;
it returns 10 records in 7.45 seconds [checked via terminal]. But when i use order by in the above query like,
select name from site order by id limit 50000,10;
the query never seems to be complete. Since the id is set as primary key, i thought it doesn’t need another indexing to speedup my query. but i don’t know where is the mistake.
Any help greatly appreciated, Thanks.
Can you try this: