php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #6311 MySQL: Unable to save result set after "INSERT" queries.
Submitted: 2000-08-23 09:22 UTC Modified: 2000-08-24 07:39 UTC
From: erik at ic dot chalmers dot se Assigned:
Status: Closed Package: MySQL related
PHP Version: 4.0.1pl2 OS: Debian GNU/Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: erik at ic dot chalmers dot se
New email:
PHP Version: OS:

 

 [2000-08-23 09:22 UTC] erik at ic dot chalmers dot se
After upgrading PHP, Apache and MySQL simultaneously I noticed the following error all over my site whenever mysql_query is called with an "INSERT" statement:

Warning: MySQL: Unable to save result set.

In this case mysql_query returns false. Looking near line 775 in ext/mysql/php_mysql.c it seems to me that
PHP_MYSQL_VALID_RESULT is returning true when it should return false.

As a temporary fix I've disabled warnings but I find them very useful while writing new scripts, so I'd like to be able to turn them back on.

Versions (last suffix is the Debian package version):
MySQL 3.23.21 - 3
PHP 4.0.1pl2 - 2
Apache 1.3.12 - 2


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-23 20:37 UTC] sniper@php.net
Please add your configure line here.

You don't happen to use any other modules with Apache which use MySQL?
If so, please use path in --with-mysql when configuring php4.

--Jani
 [2000-08-24 03:46 UTC] erik at ic dot chalmers dot se
I can't really see what options PHP was compiled with. However I disabled mod_auth_mysql and it worked.

I have filed a report in the Debian bug database (since
now I believe it to be a packaging problem, not a PHP
bug). Sorry for wasting your time!

 [2000-08-24 07:39 UTC] sniper@php.net
<?php phpinfo(); ?> shows the configure line with which
php was configured with.

You should compile php4 by yourself to get it work
when there are other modules using mysql.

And --with-mysql=/path/to/mysql fixes this.

--Jani
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Mon Oct 12 09:00:02 2026 UTC