Re: Stop PHP execution on client connection closed
| From: | Marco Lanzotti | Date: | Wed, 14 Sep 2011 08:04:07 +0000 |
| Subject: | Re: Stop PHP execution on client connection closed | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-314836@lists.php.net to get a copy of this message | ||
Il 13/09/2011 20:58, Alex Nikitin ha scritto:
> Correction on Marco's post. You can absolutely stop a mysql query
I know I can stop a query, but I don't know how to realize HTTP client
has closed connection during query execution.
My query count how many records match selected fields in a 50M records
table.
Any query field is indexed and innodb uses 20GB of RAM to store data and
indexes, but some queries take about 30 seconds to run.
When user changes filters and asks for a new count, the old queries
continue to run using DB resurces unnecessarily.
Bye,
Marco