From:
Operating system: ms
PHP version: 5.3.6
Package: MySQLi related
Bug Type: Feature/Change Request
Bug description:Mysqli_stmt->get_result() gives no error on failure
Description:
------------
Though mysqli_stmt->get_result() returns false on failure as expected, it
doesn't also generate an error on failure. Can warning-level errors be
added to help explain when/why a get fails?
Thanks,
401
Test script:
---------------
$m = new Mysqli();
$s = $m->prepare("SELECT * FROM test where(id = ?)");
$v = 1;
$s->bind_param('i', $v);
$s->execute();
$s->store_result(); // cause of get_result's failure
$r = $s->get_result();
Expected result:
----------------
Warning-level error on get_result() line 9 explaining why results failed to
return from method call, or at the very least a warning stating a failure
of some kind occurred.
Actual result:
--------------
No warning generated.
--
Edit bug report at http://bugs.php.net/bug.php?id=54385&edit=1
--
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=54385&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=54385&r=trysnapshot53
Try a snapshot (trunk):
http://bugs.php.net/fix.php?id=54385&r=trysnapshottrunk
Fixed in SVN:
http://bugs.php.net/fix.php?id=54385&r=fixed
Fixed in SVN and need be documented:
http://bugs.php.net/fix.php?id=54385&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=54385&r=alreadyfixed
Need backtrace:
http://bugs.php.net/fix.php?id=54385&r=needtrace
Need Reproduce Script:
http://bugs.php.net/fix.php?id=54385&r=needscript
Try newer version:
http://bugs.php.net/fix.php?id=54385&r=oldversion
Not developer issue:
http://bugs.php.net/fix.php?id=54385&r=support
Expected behavior:
http://bugs.php.net/fix.php?id=54385&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=54385&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=54385&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=54385&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=54385&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=54385&r=dst
IIS Stability:
http://bugs.php.net/fix.php?id=54385&r=isapi
Install GNU Sed:
http://bugs.php.net/fix.php?id=54385&r=gnused
Floating point limitations:
http://bugs.php.net/fix.php?id=54385&r=float
No Zend Extensions:
http://bugs.php.net/fix.php?id=54385&r=nozend
MySQL Configuration Error:
http://bugs.php.net/fix.php?id=54385&r=mysqlcfg