FAQ
Edit report at https://pear.php.net/bugs/bug.php?id=19148&edit=1

ID: 19148
Updated by: danielc@analysisandsolutions.com
Reported By: danielc at analysisandsolutions dot com
Summary: "undefined variable result" / _wrapQuery /
$result_class / $result_wrap_class
Status: Open
Type: Bug
Package: MDB2
Package Version: SVN
PHP Version: 5_4 SVN-2011-12-20
Roadmap Versions:
New Comment:

ATTENTION: In the first sentence of the initial comment, I meant to
say:

"The return from MDB2_Driver_Common::_wrapQuery() is a variable named
$resource."


Previous Comments:
------------------------------------------------------------------------

[2011-12-20 04:26:10] danielc

Description:
------------
The return from MDB2_Driver_Common::query() is a variable named
$resource. Calling the method with the $result_class parameter set to
false indicates one wants to get a raw resource (or mysqli_result)
object returned. But changes to variable names in revision 288591
(addressing Bug #16508) produces a state where $result has not been
set.

Along the same lines, the intention behind the $result_wrap_class
parameter and the setOption("result_wrap_class") is to have the
MDB2_Result_Common derived class passed into the Iterator derived
result_wrap_class. But the code's existing logic can produce a state
where "new $result_wrap_class($result)" would have $result not being
set, too. This is interrelated with Bug #18978 (as well as Bug #16508,
mentioned above).

------------------------------------------------------------------------

Search Discussions

  • Danielc at Dec 20, 2011 at 3:35 am
    Edit report at https://pear.php.net/bugs/bug.php?id=19148&edit=1

    ID: 19148
    Updated by: danielc@analysisandsolutions.com
    Reported By: danielc at analysisandsolutions dot com
    Summary: "undefined variable result" / _wrapQuery /
    $result_class / $result_wrap_class
    -Status: Open
    +Status: Closed
    Type: Bug
    Package: MDB2
    Package Version: SVN
    PHP Version: 5_4 SVN-2011-12-20
    -Assigned To:
    +Assigned To: danielc
    Roadmap Versions:
    New Comment:

    -Status: Open
    +Status: Closed
    -Assigned To:
    +Assigned To: danielc
    Fix committed in r321266.


    Previous Comments:
    ------------------------------------------------------------------------

    [2011-12-20 04:30:59] danielc

    ATTENTION: In the first sentence of the initial comment, I meant to
    say:

    "The return from MDB2_Driver_Common::_wrapQuery() is a variable named
    $resource."

    ------------------------------------------------------------------------

    [2011-12-20 04:26:10] danielc

    Description:
    ------------
    The return from MDB2_Driver_Common::query() is a variable named
    $resource. Calling the method with the $result_class parameter set to
    false indicates one wants to get a raw resource (or mysqli_result)
    object returned. But changes to variable names in revision 288591
    (addressing Bug #16508) produces a state where $result has not been
    set.

    Along the same lines, the intention behind the $result_wrap_class
    parameter and the setOption("result_wrap_class") is to have the
    MDB2_Result_Common derived class passed into the Iterator derived
    result_wrap_class. But the code's existing logic can produce a state
    where "new $result_wrap_class($result)" would have $result not being
    set, too. This is interrelated with Bug #18978 (as well as Bug #16508,
    mentioned above).

    ------------------------------------------------------------------------

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppear-bugs @
categoriesphp
postedDec 20, '11 at 3:30a
activeDec 20, '11 at 3:35a
posts2
users1
websitepear.php.net

1 user in discussion

Danielc: 2 posts

People

Translate

site design / logo © 2022 Grokbase