php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34037 Wrong Time conersion from db.
Submitted: 2005-08-08 15:36 UTC Modified: 2005-09-20 23:11 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: aesthete at telecenter dot ru Assigned:
Status: Not a bug Package: InterBase related
PHP Version: 4.4.0 OS: Linux 2.6.12 (Fedora Core 3)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or 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:

 

 [2005-08-08 15:36 UTC] aesthete at telecenter dot ru
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...



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-08-08 19:52 UTC] sniper@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.


 [2005-09-20 23:11 UTC] sniper@php.net
See also bug #34158

 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Mon Jul 13 01:01:25 2020 UTC