php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #12052 BUG #12006
Submitted: 2001-07-11 10:04 UTC Modified: 2002-04-13 14:56 UTC
From: rk_hora at yahoo dot com Assigned:
Status: Closed Package: InterBase related
PHP Version: 4.0.6 OS: winme
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: rk_hora at yahoo dot com
New email:
PHP Version: OS:

 

 [2001-07-11 10:04 UTC] rk_hora at yahoo dot com
BUG id #12006
Dear Derick
/* Table: LOTTERY, Owner: SYSDBA */

CREATE TABLE "LOTTERY" 
(
  "INSTALL1"	DATE NOT NULL,
  "RATE1"	NUMERIC(9, 2),
  "INSTALL2"	DATE,
  "RATE2"	NUMERIC(9, 2),
  "TOTAL"	 COMPUTED BY (rate1 + rate2),
CONSTRAINT "pkLOTTERY" PRIMARY KEY ("INSTALL1")
);
The above is my table structure.
the following is my php code that produce previous mentioned bug.
ibase_timefmt("%d/%m/%Y", IBASE_DATE);
$db = ibase_pconnect('c:/mydb.gdb', 'SYSDBA', 'masterkey');
$query = "select * from lot";
$result = ibase_query($db, $query );
$sum = 0;
$rowcount = 0;
print "<h1><center>Lottery</center></h2>";
print "<table border>";
print "<tr><th>DATE01</th><th>TOTAL1</th><th>DATE16</th><th>TOTAL2</th><th>TOTALSUM</th></tr>";
 while( $row = ibase_fetch_row( $result )){
  $s = sprintf( "<tr><td>$row[0]</td><td align = right>%s</td><td>$row[2]</td><td align = right>%s</td><td align = right>%s</td></tr>", number_format($row[1], 2),number_format($row[3], 2), number_format($row[4], 2));
  print $s;
  $sum += $row[4];
  $rowcount++;
}
 ibase_free_result($result);
 ibase_commit();
 ibase_close($db);
  sorry for any incoutesy I'm very novice for responding by this system.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-04-13 14:56 UTC] daniela@php.net
The version of PHP that this bug was reported in is too old. 
Please try the php-4.2.0RC3 from http://www.php.net/~derick/ 

If you are still able to reproduce the bug, please change the PHP
version on this bug report to the version you tested and change 
the status back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Dec 30 14:01:28 2024 UTC