php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #41025 ibase_query(): Wrong result for SELECT GEN_ID(...)
Submitted: 2007-04-08 23:00 UTC Modified: 2007-04-16 09:24 UTC
From: aesthete at telecenter dot ru Assigned: helly (profile)
Status: Closed Package: InterBase related
PHP Version: 5CVS-2007-04-08 (snap) OS: Win XP sp2
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: aesthete at telecenter dot ru
New email:
PHP Version: OS:

 

 [2007-04-08 23:00 UTC] aesthete at telecenter dot ru
Description:
------------
I have some code:
...
$sth = ibase_query('SELECT GEN_ID(GEN_DOSTAVKA_ID,1) FROM RDB$DATABASE');			

$row = ibase_fetch_assoc($sth);  // return only one row
$current_dostavka_id = $row['GEN_ID']; 
echo $current_dostavka_id;
...

On my WinXP sp2 machine with snaped php5.2-win32-200704082030 the ptinted value $current_dostavka_id is wrong and always the same:
%I64d 

The right result must be: 7120, 7121, ... for each script execution.

On linux snap php5.2-200704082030.tar.bz2 everything ok.
On php-5.2.1-Win32 everything ok.

And what about bug which I found: http://bugs.php.net/bug.php?id=34158 ... Will it be corrected?


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-04-09 07:48 UTC] tony2001@php.net
Please check if PHP 5.2.1 works for you.
There were several changes to sprintf() utilities and they might have affected it.
 [2007-04-09 19:46 UTC] aesthete at telecenter dot ru
Ok ... some statistic to php versions and this bug:

Linux (FC6):
linux stable php5.2.1.tar.bz2              - ok.
linux snap   php5.2-200704091630.tar.bz2   - ok.


Windows XP sp2:
win32 stable php-5.2.1-Win32.zip           - ok.
win32 snap   php5.2-win32-200704091630.zip - BUG!!!

php.ini in all test was the same.

What about bug which I found: http://bugs.php.net/bug.php?id=34158
... Will it be corrected?
 [2007-04-12 22:01 UTC] tony2001@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5.2-win32-latest.zip


 [2007-04-15 23:20 UTC] aesthete at telecenter dot ru
Testing results:

php5.2-latest.tar.gz        Ok
php5.2-win32-latest.zip     Ok

php.ini in all test was the same.

What about bug which I found: http://bugs.php.net/bug.php?id=34158
... Tony can you apply my patch ? ... )))
 [2007-04-16 09:24 UTC] tony2001@php.net
Great, marking as closed then.

>Tony can you apply my patch ? ... )))
I'm still waiting for an answer from the current ext/interbase maintainer.
This line seems to be there for a reason and just commenting it out is wrong (commenting out something can't be correct anyway, especially using C++ comments in C code. If you need to remove something - remove it, no need to leave it commented).
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 05:01:30 2024 UTC