SV: [PHP-DB] PHP/DB speed
| From: | Henrik Hornemann | Date: | Mon, 22 Dec 2003 11:44:01 +0000 |
| Subject: | SV: [PHP-DB] PHP/DB speed | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-32155@lists.php.net to get a copy of this message | ||
Hi,
As others have pointed out, the real problem is the huge <OPTION> list.
You may however get a slightly lower time by using mysql_fetch_row
instead of mysql_fetch_array.
Regards Henrik Hornemann
-----Oprindelig meddelelse-----
Fra: Robin Kopetzky [mailto:sparkyk@blackmesa-isp.net]
Sendt: 21. december 2003 23:16
Til: PHP DB Group
Emne: [PHP-DB] PHP/DB speed
Good afternoon!
I am writing a project and have a speed concern...
The code I am using is thus and is retrieving around 2,500
records:
$result = mysql_query($sql)
while ($row = mysql_fetch_array($result))
{
build <OPTION> stmt
}
Is there a faster method? Timed this with microtime and .9
seconds to retrieve the data and output the web page seems REAL slow.
Now this is on a T-Base-100 network but I imagine it would be like
watching paint dry in a 56K modem. Any thoughts, ideas on accelerating
this? I did try ob_start() and ob_end_flush() and no help...
Thank for any help in advance.
Robin 'Sparky' Kopetzky
Black Mesa Computers/Internet Service
Grants, NM 87020
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php