i have around (1,049,906 total, Query took 0.0005 sec) in my x table ,
If i simply retrieve trying to retrive the particular field records ,
Its tooks hardly 6 mins ,
This is my query
SELECT CUSTOMER_CODE FROM X_TBL ;
CUSTOMER_CODE => UNIQUE
THE ABOVE QUERY TOOK 6MIN ,
Tel me optimization tips for this ,
Also in some situation to search customer , i used the CUSTOMER_CODE in like ,
select CUSTOMER_CODE from X_TBL WHERE CUSTOMER_CODE LIKE "$KEY_WORD%"
yes i have index.
How to check script execution timing...in php ,
i have used below snippet but it always showing towards of increasing..
list ($msec, $sec) = explode(' ', microtime());
$microtime = (float)$msec + (float)$sec;
Regards Bharanikumar