How can I check the speed of a query using php? I ran a query that I thought would take some time to complete that involved a bunch of PCRE to format about 150 fields and it took very little time. I am about to do the same with another 600 fields.
How can I check the speed of a query using php? I ran a query that I thought would take some time to complete that involved a bunch of PCRE to format about 150 fields and it took very little time. I am about to do the same with another 600 fields.
Last edited by james438; 03-18-2010 at 05:48 AM.
To choose the lesser of two evils is still to choose evil. My personal site
This should do:
Taken from: http://uk.php.net/manual/en/function.microtime.phpPHP Code:<?php
$time_start = microtime(true);
// Code here
$time_end = microtime(true);
$time = $time_end - $time_start;
echo "Executed in $time seconds\n";
?>
Bookmarks