mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
fix bug #40161: error in the example 1
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@227512 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
36acb31fc4
commit
6520c3631a
1 changed files with 2 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version='1.0' encoding='iso-8859-1'?>
|
||||
<!-- $Revision: 1.13 $ -->
|
||||
<!-- $Revision: 1.14 $ -->
|
||||
<refentry id="function.PDO-prepare">
|
||||
<refnamediv>
|
||||
<refname>PDO->prepare()</refname>
|
||||
|
@ -100,7 +100,7 @@
|
|||
$sql = 'SELECT name, colour, calories
|
||||
FROM fruit
|
||||
WHERE calories < :calories AND colour = :colour';
|
||||
$sth = $dbh->prepare($sql, array(PDO::ATTR_CURSOR, PDO::CURSOR_FWDONLY));
|
||||
$sth = $dbh->prepare($sql, array(PDO::ATTR_CURSOR => PDO::CURSOR_FWDONLY));
|
||||
$sth->execute(array(':calories' => 150, ':colour' => 'red'));
|
||||
$red = $sth->fetchAll();
|
||||
$sth->execute(array(':calories' => 175, ':colour' => 'yellow'));
|
||||
|
|
Loading…
Reference in a new issue