MySQL Lists are EOL. Please join:

List:General Discussion« Previous MessageNext Message »
From:Yves Goergen Date:July 22 2003 2:19pm
Subject:Re: Limiting query time
View as plain text  
-----Ursprüngliche Nachricht----- 
Von: "Victoria Reznichenko" <victoria.reznichenko@stripped>
An: <mysql@stripped>
Gesendet: Dienstag, 22. Juli 2003 11:56
Betreff: Re: Limiting query time


> Troy Hakala <troyhakala@stripped> wrote:
> > Is it possible to limit the query time in MySQL (3.x or 4.0)? For 
> > example, I'd like to have any query that takes more than a specified 
> > number of seconds just quit automatically. Seems dumb, but on a web 
> > site, nobody is going to wait minutes for a query to return so they 
> > refresh anyway. So on a busy server, MySQL ends up with several queries 
> > running that all take a long time to finish which compound to make it 
> > even slower. A simple time limit would solve the problem. Yes, I know 
> > that the queries should take less time, but again, on a busy server, 
> > sometimes the longer queries do take a long time (10 minutes or more) 
> > to complete.
> 
> No, there is no option for limiting query time.
> 

i have seen an option in phpmyadmin, that sets the maximum php script execution time and
titles this to be the maximum query time.
now what happens when php is terminated while waiting for a query? i guess, mysql server
connection is terminated. and is it right that mysql aborts the query execution at this
time?
so i could do this in any other program, too, i guess. just terminate the connection after
a given time and now we have our maximum execution time.
of course, we get no result back then, but it wasn't finished anyway.

-yves

Thread
Limiting query timeTroy Hakala18 Jul
  • group before joinJohn Larsen18 Jul
    • Re: group before joinPaul DuBois18 Jul
  • (SQL Question) WHERE NOT IN A LISTTom O'Neill \(MySQL User\)18 Jul
    • Re: (SQL Question) WHERE NOT IN A LISTPaul DuBois18 Jul
  • Re: Limiting query timeVictoria Reznichenko22 Jul
  • Re: Limiting query timeYves Goergen22 Jul