ID:               24952
 Comment by:       grimskonk at hotmail dot com
 Reported By:      sirber at myrealbox dot com
 Status:           Open
 Bug Type:         PostgreSQL related
 Operating System: Gentoo Linux
 PHP Version:      4.3.2
 New Comment:

i would also like to add that we tried something to find the bug.. and
it came up with a really weird error.

In that same page where we only insert one row, we tried adding 2 new
rows with a SELECT CURRVAL inbetweeen.

Like this : 
//_____________________1st insert_______________________
pg_query($ConnectID,"INSERT INTO tblassdivision ....")
rsCur = pg_fetch(pg_query(SELECT currval from tblass.")
<script> alert(rsCur->currval) </script>

//_____________________2nd insert_______________________
pg_query($ConnectID,"INSERT INTO tblassdivision ....")
rsCur = pg_fetch(pg_query(SELECT currval from tblass.")
<script> alert(rsCur->currval) </script>

It inserted 4 rows with the ids 51,52,53,54 
We got 2 popups.. but the weird thing is that it poped
[53] and [54]   instead of   [51][53] / [52][54]

As if a set of inserts were being made BEFORE the actual code, AND THEN
it proceeds to the actual code


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

[2003-08-05 11:48:00] sirber at myrealbox dot com

Seems to bug with Internet Explorer only...

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

[2003-08-05 11:42:39] sirber at myrealbox dot com

Description:
------------
Gentoo make.conf:

USE="-X -gnome -kde -qt perl 3dnow mmx crypt -cups gd gif -gtk imap
-java jpeg mbox ncurses png
postgres samba sse ssl tcpd zlib x86 apache"

With apache (1 or 2), PHP 4.3.2-x and Postgresql 7.3.2-x,
a pg_query($ConenctID, "INSERT INTO ..."); insert 2 elements. If I add
mod_ssl, and use ssl, the same page insert only 1 element, which is
normal. 

We made a lot of tests, and the pg_query is executed only once in both
case, and the page is loaded only once too. 

Reproduce code:
---------------
pg_query($ConnectID,"INSERT INTO tblassdivision (asscontratid,
dateeffective, dateterminaison, concontactid, entdivisionid,
conadresseid, creepar, creedate) values ( '$contratID',
$txtDateEffective, $txtDateTerminaison, '$contactID', '$divisionID', 
'$conAdrID' ,'$sUserID', now())");

Expected result:
----------------
1 new row

Actual result:
--------------
2 new rows without mod_ssl
1 new row with mod_ssl


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


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

Reply via email to