Usage
in Bootstrap file
// turn on profiler:
$db->getProfiler()->setEnabled(true);
in Action before all queries
$profiler = $db->getProfiler();
Bottom of the function
foreach ($profiler->getQueryProfiles() as $query) {
echo '
'.$query->getQuery();
echo ' TIME: ' .$query->getElapsedSecs()." Seconds";
}
It will list the Connection Time and all other executed queries with taken time
No comments:
Post a Comment