Skip to content

Commit

Permalink
use correct variables
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul M. Jones committed Feb 19, 2014
1 parent ef084df commit 3af3f01
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -255,10 +255,8 @@ $bind = array('foo' => 'bar', 'baz' => 'dib');
// the native PDO way to "fetch all" where the result is a sequential array
// of rows, and the row arrays are keyed on the column names
$pdo = new PDO(...);
$pdo->prepare($stm);
$stm->bindValue('foo', $bind['foo']);
$stm->bindValue('bar', $bind['bar']);
$sth = $stm->execute();
$sth = $pdo->prepare($stm);
$sth->execute($bind);
$result = $sth->fetchAll(PDO::FETCH_ASSOC);

// the ExtendedPdo way to do the same kind of "fetch all"
Expand Down

0 comments on commit 3af3f01

Please sign in to comment.