ID: 49258 Updated by: u...@php.net Reported By: grzegorz at heex dot pl -Status: Open +Status: Closed Bug Type: PDO related Operating System: Win XP Sp3 PHP Version: 5.3.0 New Comment:
Closing in favour of http://bugs.php.net/bug.php?id=49262 . This one is a duplicate because: PDO emulation used, no type specified = default to type string = #49262 scenario. Previous Comments: ------------------------------------------------------------------------ [2009-08-14 17:40:34] grzegorz at heex dot pl Description: ------------ PHP crashes if there is no PDO_Type of param Reproduce code: --------------- $pdo = new PDO("mysql:host=localhost;dbname=[base];",'[user]','[pass]'); $sth = $pdo->prepare("SELECT * FROM lng WHERE lng_id=:Id"); $id = 1; //causes PHP crash $sth->execute(array(':Id'=>$id)); //OR //$sth->bindParam(':Id',$id);$sth->execute(); //works fine: //$sth->bindValue(':Id',$id,PDO::PARAM_INT); //$sth->execute(); die('OK'); Expected result: ---------------- OK Actual result: -------------- PHP CGI/FastCGI crash ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=49258&edit=1