Doc #54416 [Opn->Bgs]: Mysqli return warning if calling more than one stored procedure
| From: | frozenfire@php.net | Date: | Mon, 02 May 2011 06:51:20 +0000 |
| Subject: | Doc #54416 [Opn->Bgs]: Mysqli return warning if calling more than one stored procedure | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-6334@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=54416&edit=1
ID: 54416
Updated by: frozenfire@php.net
Reported by: anjusb712 at gmail dot com
Summary: Mysqli return warning if calling more than one
stored procedure
-Status: Open
+Status: Bogus
Type: Documentation Problem
Package: MySQLi related
Operating System: Ubuntu
PHP Version: 5.2.17
Block user comment: N
Private report: N
New Comment:
This looks to be an issue with your code, rather than an issue with the
MySQLi
extension. I think you may be using mysqli_free_result, which doesn't
exist,
instead of mysqli_stmt_free_result.
Before submitting a bug report, it's best to check with a support forum
like
##php on Freenode to ensure that your code is not malformed.
Previous Comments:
------------------------------------------------------------------------
[2011-03-29 11:15:56] anjusb712 at gmail dot com
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 this bug report at http://bugs.php.net/bug.php?id=54416&edit=1