|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-01-28 03:47 UTC] abhargav at in dot ibm dot com
[2009-03-06 03:51 UTC] abhargav at in dot ibm dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 09:00:01 2025 UTC |
Description: ------------ When using a prepared statement with a like clause with '%?%' the pdo driver segfaults. This should either work or throw an error. Using it in the syntax of "fname like ?" and having the variable be "%Lud%" works as intended. This is minor but it should not be crashing. Reproduce code: --------------- <? putenv("INFORMIXDIR=/opt/informix"); putenv("INFORMIXSERVER=llama"); $dbh = new PDO("informix:host=server; service=1516; database=stores_demo; server=server; protocol=onsoctcp;EnableScrollableCursors=1", "informix", "password"); $sqlline = "select fname from customer where fname like '%?%'"; $val = "Lud"; $sth = $dbh->prepare($sqlline); $sth->execute(array($val)); $row = $sth->fetch(); print_r($row); Expected result: ---------------- Array ( [FNAME] => Ludwig [0] => Ludwig ) Actual result: -------------- llama:/www/fht # php test.php Segmentation fault