i am using this query
$query = "SELECT SQL_CACHE * FROM `like` WHERE `id` ='$id' LIMIT 0 , 1";
$result = @mysql_query ($query); // Run the query.
$row = mysql_fetch_array($result);
$crap= $row['crap'];
is there any faster way to execute this query?
i want to execute this as fast as possible
i am using php
thanks
Do you have an index in place on the
idcolumn? That’s the only way I can think to speed things up.And maybe selecting only the
crapcolumn specifically instead of*.If this isn’t fast enough for you and you control your server infrastructure, you may want to look into caching solutions like Memcache.