alaa_ecv_tc
In Runtime
- Messages
- 147
- Location
- Syria
Hi ..
While testing some codes in PHP and MySQL I had this :
There are 1 million posts where 'prefix' clumon for them all is set to 'add' .
total size of db is about 32Mb .
the runned code is :
SELECT * FROM 'posts' WHERE deleter_id = '0' AND prefix = 'add' ORDER BY id DESC LIMIT 25 OFFSET 900000 ;
In Phpmyadmin it took about 60.6 sec to show results ..
In my program I got that max time for operation is 20 secounds .. and died !!
How can I avoide that limit like phpmyadmin did ?
Thanks
While testing some codes in PHP and MySQL I had this :
There are 1 million posts where 'prefix' clumon for them all is set to 'add' .
total size of db is about 32Mb .
the runned code is :
SELECT * FROM 'posts' WHERE deleter_id = '0' AND prefix = 'add' ORDER BY id DESC LIMIT 25 OFFSET 900000 ;
In Phpmyadmin it took about 60.6 sec to show results ..
In my program I got that max time for operation is 20 secounds .. and died !!
How can I avoide that limit like phpmyadmin did ?
Thanks