MySQL Forums
Forum List  »  Optimizer & Parser

prepared statement query takes 3s for a few hundred lines - query issue
Posted by: Michael W.
Date: November 16, 2015 11:14AM

Hi there,

my programmers send me the latest version of an mysql based app. I complaint it is just too slow. Checking the api myself I found out that there is an idle time of 3000ms after the get command. Probing the threads on the server, I see no processor nor I/O getting above 5% and even the SQL tools I use report idle while the request is working. So I guess the prepared statement or the tables are prepared in a way that the database need endless to collect the data.

1. Any tip how to analyse the system any better (more precise)
2. The app is using this query:

SELECT `a`.* FROM `airspaces` `a` LEFT JOIN `airspace_points` `p` ON `a`.`id` = `p`.`airspace_id` WHERE `p`.`grid` IN (5702, 5282) AND `a`.`category` <> "FIR" GROUP BY `a`.`id`;
Indeed nothing worth without the structure of the db, but anyhow is there an something suspicious why the query takes so long?

3. Other tips how to crack that issue?

Loocking forward to getting guidance...

Options: ReplyQuote


Subject
Views
Written By
Posted
prepared statement query takes 3s for a few hundred lines - query issue
1494
November 16, 2015 11:14AM


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.