[eluser]outtolunch[/eluser]
Hello,
I was wondering, how i could increase the performance of getting-displaying results from the database.
I've got a massive SQL query, which runs through data in a table called "ads" according the latitude and longitude of the postcodes listed in the other table called "postcodes".
It starts with the small radius to get the nearest "ads" and if it doesn't find anything it increases the radius and moves on till it finds something.
It some good maths hidden in that sql query to get the results in a "circle" for the accuracy purposes.
Everything is processed within the "model", while executing the sql queries and printing the results into the tables, after that i just call the model function within the "view" to display it on the page.
The whole thing works nicely, just a bit too slow. Previously it was laying on a "hand/hard-coded" php website. I decided to put everything into codeigniter.
I've checked the elapsed time, which says 1-1,5 seconds, I would like to make 0,5-0,8 seconds if thats possible.
If someone has some tips & tricks, i would be please to listen to that.