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

ID: 14682
Updated by: cweiske@php.net
Reported By: mike at silverorange dot com
Summary: MDB2_Driver_Common::prepare() $result_types docs
incorrect
-Status: Open
+Status: Closed
Type: Documentation Problem
Package: MDB2
Operating System: Irrelevant
Package Version: 2.4.1
PHP Version: Irrelevant
-Assigned To:
+Assigned To: cweiske
Roadmap Versions:
New Comment:

-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: cweiske
This bug has been fixed in SVN.

If this was a documentation problem, the fix will appear on
pear.php.net by the end of next Sunday (CET).

If this was a problem with the pear.php.net website, the change should
be live shortly.

Otherwise, the fix will appear in the package's next release.

Thank you for the report and for helping us make PEAR better.




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

[2008-09-26 10:23:22] gauthierm

Here is the message reported in IRC:

< mslade> I'm trying to prepare and exec a simple select on MySQL,
and am getting a "not supported" error. getUserInfo reveals "Error
message: 1 for 0 is not a supported column type"

The API docs at
http://pear.php.net/package/MDB2/docs/2.4.1/MDB2/MDB2_Driver_Common.html#methodprepare
use null instead of true as the default value for the method.

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

[2008-09-26 05:16:24] quipo

The documentation should be correct, see the _wrapResult() method. What
error are you getting?

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

[2008-09-21 13:49:03] gauthierm

Description:
------------
The end-user documentation at
http://pear.php.net/manual/en/package.database.mdb2.intro-execute.php
has incorrect documentation for the prepare() method's third parameter
($return_types). The current documentation states:

"Since DML (data manipulation language - INSERT, UPDATE, DELETE)
statements have different return values than data fetches the prepare()
accepts a third parameter. This parameter should be set to
MDB2_PREPARE_MANIP for DML statements. For data reads it should either
be set to MDB2_PREPARE_RESULT, an array of data types for each of the
columns in the result set or TRUE in order to automatically detect the
data types in the result set."

This is incorrect as passing "TRUE" for $result_types results in an
error instead of automatic type detection. The correct value to pass for
automatic type detection is null (or you can simply not specify the
third parameter).

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

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppear-bugs @
categoriesphp
postedOct 14, '09 at 9:07p
activeOct 14, '09 at 9:07p
posts1
users1
websitepear.php.net

1 user in discussion

Cweiske: 1 post

People

Translate

site design / logo © 2022 Grokbase