Use MySQL Query Caching
-----Original Message-----
From: Aasef Iqbal [mailto:[EMAIL PROTECTED]
Sent: Monday, June 28, 2004 4:46 PM
To: [EMAIL PROTECTED]
Subject: slow query when searching database of over 2 million records
Hi,
I am working on a web project project where one of my pages has to show
a count of total number of matches found and short text for few of them,
just like a search engine.
I need to issue two queries first one fetches a count for total matches
found and second query finds detail to 10/20 of those results as
specified by the user. the quries are
select count(distinct CURL) as rc from tbl_directory where MATCH
(CName,DSCR) AGAINST ("software project management" ) and LinkType = 1
(Time Taken for Total Count :: 207.27026605606)
select distinct CURL,CName,DSCR, MATCH (CName,DSCR) AGAINST ("software
project management" ) as rel from tbl_directory where MATCH (CName,DSCR)
AGAINST ("software project management" ) and LinkType = 1 limit 0, 10
(0.26 seconds)
first query always takes much longer time whenever I search for
something new, n in subsequent searches the result is quite satisfactory
(as it comes from query
cache)
is there anyway to speed up the search, im querying some 2 million
records.
thanx in adavnce
Asif Iqbal
Cool Things Happen When Mac Users Meet! Join the community in Boston
this July: www.macworldexpo.com
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]