note 72089 deleted from ref.pdo by bjori
| From: | bjori@php.net | Date: | Sun, 11 Feb 2007 12:33:33 +0000 |
| Subject: | note 72089 deleted from ref.pdo by bjori | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-123245@lists.php.net to get a copy of this message | ||
Note Submitter: letsgolee at lycos dot co dot kr
----
you cannot set a variable like string or int as a second parameter when you use bindParam()
function.
$stmt = $db->prepare('insert into test (no, memo) values (?, ?);
$stmt->bindParam(1, 50); // NOT WORK!
$no = 50;
$stmt->bindParam(1, $no); // WORK!