<div>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">I am trying to use memcached for a web application with search functionality. All search queries work on certain number of parameters ( the parameters are numbers or boolean ).
<br>There is also an additional parameter ( date range ) which is also attached to the query. <br><br>One of my sample query ( sql ) looks like <br>select * from table where type = 1 and ( occurred_date between 'some date' and 'some date');
<br><br>Has someone out here dealt with date range based querying using memcached before or have any ideas around how to use ( if at all ) memcached for such dynamic queries ? </blockquote>
<div> </div>
<div>You could store each query indexed by the MD5 of the mysql query. Then when doing a new query, search to see if it's already in the cache. </div></div>