List:General Discussion« Previous MessageNext Message »
From:mos Date:June 14 2007 6:28pm
Subject:Re: Creating a Cache field
View as plain text  
At 10:22 AM 6/14/2007, Ins wrote:

>Hi,
>
>I have a MySQL database of thousands of external webpage links. I want to
>extract cache page for each and put the content in my database, so that I
>can display, just like google, a cached page for each weblink.
>
>How do I go about it? How to extract cache, how to store it and how to
>display it. What scripts are necessary?
>
>Ins

Ins,
     MySQL automatically caches queries so subsequent queries to the same 
link are fetched from memory. This is automatic and you don't have to do 
anything except to adjust your query_cache_size to be large enough for the 
queries that are repetitive. (You may need to buy more RAM if you want a 
large query cache) I don't think there is any point caching links that are 
never going to be requested. See the tutorial at 
http://www.databasejournal.com/features/mysql/article.php/3110171

You could also put the entire table into a memory table but that will eat 
of memory. It may work ok for 25,000 rows, but if you exceed 1 million 
rows, it could be overkill and may not be faster than the query cache on a 
normal MyISAM table

Mike 
Thread
Creating a Cache fieldIns14 Jun
  • Re: Creating a Cache fieldmos14 Jun