php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #432 mysql_affected_rows returns strange values
Submitted: 1998-06-03 13:23 UTC Modified: 1998-09-22 10:28 UTC
From: koles at atrey dot karlin dot mff dot cuni dot cz Assigned: zeev (profile)
Status: Closed Package: MySQL related
PHP Version: 3.0 Release Candidate 5 OS: linux 2.0.33 (redhat 5.0)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
50 - 1 = ?
Subscribe to this entry?

 
 [1998-06-03 13:23 UTC] koles at atrey dot karlin dot mff dot cuni dot cz
This simple script

    mysql_connect("localhost", "", "");
    if ($res = mysql("test", "UPDATE user SET login='abcd' WHERE id=1"))
    {
        echo mysql_affected_rows() . " rows<BR>\n";
    }

displays 589505315 (but sometimes 0), but table "user"
contains less than 20 rows. php3-rc4 works fine.

i have php3 compiled as apache module (apache 1.3b7) and
i have mysql-3.21.29 installed.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-09-22 10:28 UTC] zeev
This is most likely a compilation/linking problem.
This really can't be coming from PHP - make sure you're
linking PHP with a library from the same distribution
as the header files you're compiling it with.
---
Most definitely a compilation and/or linking issue, it
works fine in hundreds of setups...
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 05:01:28 2024 UTC