Jump to content

Strange query


Recommended Posts

In slow quey log of my site i see this strange query that has examined over 180000 rows.

Is this normal?

# Thu Mar 10 06:02:14 2011
# Query_time: 8.307048  Lock_time: 1.372453 Rows_sent: 1  Rows_examined: 189305
use crazyluk_prestashop;
SELECT COUNT(DISTINCT cp.`id_connections`)
       FROM `ps_connections_page` cp
       WHERE TIME_TO_SEC(TIMEDIFF(NOW(), cp.`time_start`)) < 900 LIMIT 1

Link to comment
Share on other sites

That module it's about the statistics shown on the back office home page. If you can, disable or uninstall that module. In the first case the database will not be deleted, so you could restart those statistics. For sure, if you need statistics about accesses etc.. you could use Google analytics thought the specific Prestashop modules.

Link to comment
Share on other sites

"Google Analytics " and the BO home stats are two different modules, so you can switch off only the second one. To avoid big issue, instead of uninstalling the module, you could start disabling it. Thus you could check the platform behavior for some days and then, if you want, you could uninstall it or enable it again. For sure, in the last case you should check if it's possible to clean the database because the involved query is about a too big table.

Link to comment
Share on other sites

×
×
  • Create New...