Created
December 3, 2008 08:11
-
-
Save tony-landis/31483 to your computer and use it in GitHub Desktop.
Quick and dirty PDO vs ADOdb benchmark
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
#Quick and dirty PDO vs ADOdb benchmark | |
#PDO benchmark script: | |
$db = new PDO("mysql:dbname=logs;host=127.0.0.1", "root", ""); | |
$rs = $db->query("select * from ses limit 10")->fetchAll(PDO::FETCH_ASSOC); | |
foreach($rs as $r) {} | |
#ADOdb benchmark script | |
require_once("adodb5/adodb.inc.php"); | |
$ADODB_FETCH_MODE = ADODB_FETCH_ASSOC; | |
$db = NewADOConnection("mysql://root:@127.0.0.1/logs"); | |
$rs = $db->Execute("select * from ses limit 10"); | |
foreach($rs as $r) {} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment