[PHP-DB] MySQL vs. Session array

2010-04-07 Thread 3dgtech
Quick question. I have an AJAX component that fires a like query for  
each key up event (since it's a like % query there is no indexing or  
caching possible). While everything works fine, I was contemplaining  
downloading the ~1500 rows into a session var as array, offloading the  
(seperate) mysql server and utilizing the (underutilized) php server.  
Any thoughts?

PS: maybe even offload it to a JavaScript function??

Thank you,
Eli

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] MySQL vs. Session array

2010-04-07 Thread Peter Lind
On 8 April 2010 00:13, 3dgtech syst...@3dgtech.com wrote:
 Quick question. I have an AJAX component that fires a like query for each
 key up event (since it's a like % query there is no indexing or caching
 possible). While everything works fine, I was contemplaining downloading the
 ~1500 rows into a session var as array, offloading the (seperate) mysql
 server and utilizing the (underutilized) php server. Any thoughts?

You'd be better off storing stuff in memcache than session, would be
my opinion - session is per user, so you wouldn't get much cache reuse
out of it.

-- 
hype
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
/hype

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php