#24244 [Com]: odbc_errormsg() sometimes returns a bad string when no error occurs

From: Date: Wed, 15 Oct 2003 08:27:55 +0000
Subject: #24244 [Com]: odbc_errormsg() sometimes returns a bad string when no error occurs
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-49046@lists.php.net to get a copy of this message
 ID:               24244
 Comment by:       thorsten at rinne dot info
 Reported By:      bl at btn dot de
 Status:           No Feedback
 Bug Type:         ODBC related
 Operating System: Red Hat Linux
 PHP Version:      4.3.2
 New Comment:

Hi,

I'm using PHP 4.3.3 on W2K with a IBM DB2 database version 8.1. If an
error occured, I got a normal error code in odbc_error() and
odbc_errormsg(). After that, I execute a correct SQL statement and the
error messages are still left in odbc_error() and odbc_errormsg().
There are also junk messages after some correct and successfull queries
in odbc_error() and odbc_errormsg().

This seems to be an OS independent bug in PHP.


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

[2003-08-01 06:09:31] sniper@php.net

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.



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

[2003-07-27 13:19:29] iliaa@php.net

Actually I wanted to see the error id not the error message. So please
tell me what is the output of:
var_dump(odbc_error())

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

[2003-06-26 18:23:37] sniper@php.net

Do not add comments to your own report, use this link:
http://bugs.php.net/bug.php?id=24244&edit=2


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

[2003-06-26 04:07:16] mb at btn dot de

Output of var_dump(odbc_errormsg()) as follows:

string(146)
"31:*.bz2=01;31:*.bz=01;31:*.tz=01;31:*.rpm=01;31:*.cpio=01;31:*.jpg=01;35:*.gif=01;35:*.bmp=01;35:*.xbm=01;35:*.xpm=01;35:*.png=01;35:*.tif=01;35:"

string(122)
"1:*.tz=01;31:*.rpm=01;31:*.cpio=01;31:*.jpg=01;35:*.gif=01;35:*.bmp=01;35:*.xbm=01;35:*.xpm=01;35:*.png=01;35:*.tif=01;35:"

These are only two examples. I had to reproduce the error in a small
script to generate these. That's why the variety is not that great like
in our production environment where we currently use a dirty
workaround.

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

[2003-06-18 10:24:52] iliaa@php.net

What does var_dump(odbc_error()) return after a valid query?

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

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/24244

-- 
Edit this bug report at http://bugs.php.net/?id=24244&edit=1


Thread (13 messages)

« previous php.bugs (#49046) next »