MySQL Forums
Forum List  »  Memory Storage Engine

Caching Queries
Posted by: Mohamed Hanifa
Date: January 25, 2006 02:15PM

Greetings,
I am having a problem.
Here I go, I am using the Enron database with some tables having as much as half million entries.Query processing for some SQL statements can take as much as 4 mins.The database is connected to visualization program[Java Program] so this is too slow.

How I have so far dealt with this situation is here,
In MySql Administrator, Health ->System Variables->Memory->caches
|-> query_cache_size = 50 000 000
Here I have set the cache to 50 MB.
Lets say I have 20 queries , I just open Query Browser and run all these queries beforehand.So they got stored in cache somehow.
So when I run the visualization program , the queries get retrieved from the cache and everything is fast.

However, this process is not good in the sense that the cache gets cleared everytime i restart the comp.

So Qn 1.: Any of U guys know a way to permanently store the data in the cache.
Or does anyone have better solution
PS : All my queries are only "select" based and the database entries are
never changed.

Qn 2. And running all these queries is also time consuming, to type one by
one and run them as every query takes 3-4 mins.So far running 30
queries , it takes almost 2 hrs.Is there a way to write some script in
MySQl and run all these at one shot.

Any help is deeply appreciated.

Thanks for helping.

Options: ReplyQuote


Subject
Views
Written By
Posted
Caching Queries
4888
January 25, 2006 02:15PM
3648
January 26, 2006 04:45AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.