#34037 [NEW]: Wrong Time conersion from db.
From: aesthete at telecenter dot ru
Operating system: Linux 2.6.12 (Fedora Core 3)
PHP version: 4.4.0
PHP Bug Type: InterBase related
Bug description: Wrong Time conersion from db.
Description:
------------
I have 2 machines
WinXp(test server): php 4.4.0, apache 1.3.33, firebird-1.5.2
Linux(working serv): php 4.4.0, apache 1.3.33, firebird-1.5.2 (php
compilled with interbase and bcmath options)
I have simple firebird table:
CREATE TABLE ZAP_KNIGA (
TIME_ TIME NOT NULL,
PRIMECH VARCHAR(500));
Some data in table rows (TIME_ colomn):
10:00:00
10:34:02
11:05:10
(this is right values in db ... cheked up with IBExpert).
My time zone:
WinXP: GMT+3 Moscow
Linux:
[root@darkstar tests]# date
Ïíä Àâã 8 17:02:19 MSD 2005
I have php script:
$sql_str = 'SELECT TIME_, PRIMECH FROM ZAP_KNIGA';
$sth = ibase_query($sql_str) or die('error');
while ($row = ibase_fetch_assoc($sth))
echo $row['TIME_'].' '.$row['PRIMECH'].'<br>';
My problem:
When i go to my test site on winxp, explorer shows correct rows:
10:00:00
10:34:02
11:05:10
When i put my script on Linux serv, explorer shows wrong rows:
23:15:52
23:15:52
23:15:52
(one value for all rows!!!!!!)
When i go to linux site from linux console using 'links'
rows is WRONG!
The first idea was something wrong in time zones client and server
machines, but php shows one value in all rows and doesnt calculate GMT
offsets from each time value.
How can I resolv this problem ?
P.S: Sorry my English...
--
Edit bug report at http://bugs.php.net/?id=34037&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=34037&r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=34037&r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=34037&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=34037&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=34037&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=34037&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=34037&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=34037&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=34037&r=support
Expected behavior: http://bugs.php.net/fix.php?id=34037&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=34037&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=34037&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=34037&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=34037&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=34037&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=34037&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=34037&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=34037&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=34037&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=34037&r=mysqlcfg
Thread (3 messages)
- aesthete at telecenter dot ru