Doc #54416 [NEW]: Mysqli return warning if calling more than one stored procedure

From: Date: Tue, 29 Mar 2011 09:15:59 +0000
Subject: Doc #54416 [NEW]: Mysqli return warning if calling more than one stored procedure
Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-6162@lists.php.net to get a copy of this message
From: Operating system: Ubuntu PHP version: 5.2.17 Package: MySQLi related Bug Type: Documentation Problem Bug description:Mysqli return warning if calling more than one stored procedure Description: ------------ <?php $con = mysqli_connect("localhost","root","root","hcms"); //procedureCall.php $qryProdChk = "call Get_schoolProductDetail(0,0,0,0,'')"; $rsProdChk = mysqli_query($con,$qryProdChk); $rowProdChk = mysqli_fetch_array($rsProdChk,MYSQLI_ASSOC); mysqli_free_result($rsProdChk); echo $qryProdDet = "call Get_keltronProduct(".$proddId.",0,0,0,'".$slNo."')"; $rsProdDet = mysqli_query($con,$qryProdDet); $rowProdDet = mysqli_fetch_array($rsProdDet,MYSQLI_ASSOC); ?> On executing this script I got a warning like Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in /var/www/storedProcedure/procedureCall.php on line 13 Plz help me to solve this issue..... Test script: --------------- <?php $con = mysqli_connect("localhost","root","root","hcms"); //procedureCall.php $qryProdChk = "call Get_schoolProductDetail(0,0,0,0,'')"; $rsProdChk = mysqli_query($con,$qryProdChk); $rowProdChk = mysqli_fetch_array($rsProdChk,MYSQLI_ASSOC); mysqli_free_result($rsProdChk); echo $qryProdDet = "call Get_keltronProduct(".$proddId.",0,0,0,'".$slNo."')"; $rsProdDet = mysqli_query($con,$qryProdDet); $rowProdDet = mysqli_fetch_array($rsProdDet,MYSQLI_ASSOC); ?> Expected result: ---------------- I want to compare the values from the result of the two procedures. -- Edit bug report at http://bugs.php.net/bug.php?id=54416&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=54416&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=54416&r=trysnapshot53 Try a snapshot (trunk): http://bugs.php.net/fix.php?id=54416&r=trysnapshottrunk Fixed in SVN: http://bugs.php.net/fix.php?id=54416&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=54416&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=54416&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=54416&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=54416&r=needscript Try newer version: http://bugs.php.net/fix.php?id=54416&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=54416&r=support Expected behavior: http://bugs.php.net/fix.php?id=54416&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=54416&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=54416&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=54416&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=54416&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=54416&r=dst IIS Stability: http://bugs.php.net/fix.php?id=54416&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=54416&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=54416&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=54416&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=54416&r=mysqlcfg

« previous php.doc.bugs (#6162) next »