MySQL Forums
Forum List  »  Performance

Re: Slow JOIN to convert IP to Country Code
Posted by: Harutyun Drnoyan
Date: May 29, 2009 10:55AM

Hi. I did some tests and found some information in profiling and slow query log.
The slow query log shows Rows_examined: 1 010 815.
Profiling shows that ~99% of execution time takes the stage "Copying to tmp table". After I've changed my iplist table to use char columns instead of varchars the total time of query dropped to ~7.524 seconds, but still huge amount of that time(7.52258=99.98%) takes the stage of copying to tmp table. So it seems to me the only way to optimize this query is speed up this part, but I do not know how.

If you have any idea it will be really helpful.

Thanks.



Edited 1 time(s). Last edit at 05/30/2009 01:02AM by Harutyun Drnoyan.

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.