php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #5634 mysql_insert_id retruns 0 in php4 but works in php3
Submitted: 2000-07-17 06:12 UTC Modified: 2000-08-18 20:56 UTC
From: s dot benard at systemic dot fr Assigned:
Status: Closed Package: MySQL related
PHP Version: 4.0.1pl2 OS: Linux Mandrake 7.02
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: s dot benard at systemic dot fr
New email:
PHP Version: OS:

 

 [2000-07-17 06:12 UTC] s dot benard at systemic dot fr
I installed both PHP3 (3.0.16) and PHP4 (4.0.1pl2) on the same server with mysql 3.22.32 on an apache server (1.3.12).
I used the --enable-versioning so php3 and php4 work together.

when I use the mysql_insert_id function, it works fine with php3 but the same code returns nothing with php4 on the same server...

I first thought it was misconfiguration of my server. So, I installed a second server for tests purposes and got same results. the insertion is ok, no error messages but in php4, it returns nothing.

don't really know if it's a bug. but don't know where this come from.

s.benard



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-07-17 09:42 UTC] rasmus at cvs dot php dot net
How did you configure PHP?  --with-mysql or --with-mysql=/some/path ?
The difference here being that the first version uses the bundled mysql client library and the second uses the client library installed on your system. 
The bundled library should be completely backward compatible, but who knows.  Let us know if changing the library makes a difference.
 [2000-08-18 20:56 UTC] sniper@php.net
No feedback from user.

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