Jump to content

MySQL Query Timeout?


andygrant

Recommended Posts

Hi

 

I'm executing a MySQL query and its getting data from two linked tables that have around 4500 and 7500 rows. My query should return about 4500 results but it seems to be timing out. When loading the page in IE it just gives a page cannot be found and Firefox shows a Popup asking if i want to open the file in Dreamweaver or save the file.

 

If i alter the quert slightly so it only returns 200-300 results it works fine.

 

The results are actually seperated onto 25 per page but it still wont work. Even when only select COUNT(*) it doesn't work. Is there a limit to the amount of results that can be returned. Looking in phpMyAdmin the size of the tables are 250-300kb in size.

 

Thanks in advance.

Link to comment
Share on other sites

It is common for large queries to cause PHP scripts to exceed their memory limits.

 

What errors are being reported?

 

To ensure all errors are reported in the php.ini file set:

display_errors = On

track_errors = On

html_errors = On

log_errors = On

error_log = /var/tmp/error.log

NOTE: On a production server you don't want to report back errors to potential hackers so there just log errors!

 

To increase the memory limit in the php.ini file set:

memory_limit = 128M ; Maximum amount of memory a script may consume (default 8M)

 

Paul D.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.