Fixed the Garvin's calculations.

This commit is contained in:
Alexander M. Turek
2003-03-13 20:05:28 +00:00
parent 9d0a25a779
commit 3c5e254265
2 changed files with 16 additions and 16 deletions

View File

@@ -5,6 +5,9 @@ phpMyAdmin - Changelog
$Id$ $Id$
$Source$ $Source$
2003-03-13 Alexander M. Turek <rabus@users.sourceforge.net>
* server_status.php3: Fixed the Garvin's calculations.
2003-03-13 Marc Delisle <lem9@users.sourceforge.net> 2003-03-13 Marc Delisle <lem9@users.sourceforge.net>
* libraries/sqlparser.lib.php3: analyzer: where_clause_identifiers * libraries/sqlparser.lib.php3: analyzer: where_clause_identifiers
@@ -17,15 +20,15 @@ $Source$
* libraries/build_dump.lib.php3, db_details_structure.php3, db_printview.php3, * libraries/build_dump.lib.php3, db_details_structure.php3, db_printview.php3,
pdf_schema.php3, tbl_dump.php3, tbl_printview.php3, tbl_properties_structure.php3, pdf_schema.php3, tbl_dump.php3, tbl_printview.php3, tbl_properties_structure.php3,
lang/*: RFE #7000385: Export AUTO_INCREMENT field. lang/*: RFE #7000385: Export AUTO_INCREMENT field.
Display Create/Update/Check_time in PDF-Pages, printview, DB/Table structure and table Display Create/Update/Check_time in PDF-Pages, printview, DB/Table structure and table
dumps, if information is available (gathered by 'SHOW TABLE STATUS' for MySQL 3.23.XX). dumps, if information is available (gathered by 'SHOW TABLE STATUS' for MySQL 3.23.XX).
* config.inc.php3 - Altered comments for PMA_* tables for easier integration and more * config.inc.php3 - Altered comments for PMA_* tables for easier integration and more
clarity. Make it easier to enable defaults (RFE #695265) clarity. Make it easier to enable defaults (RFE #695265)
2003-03-12 Garvin Hicking <me@supergarv.de> 2003-03-12 Garvin Hicking <me@supergarv.de>
* db_details_structure.php3: When using Alias-Displays for Tables, fix bug when a tablename * db_details_structure.php3: When using Alias-Displays for Tables, fix bug when a tablename
was not displayed if it has no comment. was not displayed if it has no comment.
* libraries/display_tbl.lib.php3 RFE #550554 - Execute SQL bookmarks when browsing the * libraries/display_tbl.lib.php3 RFE #550554 - Execute SQL bookmarks when browsing the
bookmarktable. bookmarktable.
* db_details_structure.php, left.php3, tbl_properties_links.php3, libraries/bookmark.lib.php3: * db_details_structure.php, left.php3, tbl_properties_links.php3, libraries/bookmark.lib.php3:
RFE #550552: Change default initial query for browse mode, if a bookmark with the same RFE #550552: Change default initial query for browse mode, if a bookmark with the same
@@ -45,14 +48,14 @@ $Source$
* tbl_move_copy.php3, tbl_properties_operations.php3: RFE #571838 : * tbl_move_copy.php3, tbl_properties_operations.php3: RFE #571838 :
Add 'DROP TABLE IF EXISTS' checkbox. Will maintain any existing PMA_* entries Add 'DROP TABLE IF EXISTS' checkbox. Will maintain any existing PMA_* entries
for that table. for that table.
* tbl_properties_export.php3, db_details_export.php3, * tbl_properties_export.php3, db_details_export.php3,
libraries/display_export.lib.php3: Reworked DB/Table export, so that DB libraries/display_export.lib.php3: Reworked DB/Table export, so that DB
export now is a perfect look-alike except for a multi-tables dropdown. export now is a perfect look-alike except for a multi-tables dropdown.
Put the code to display the export into a seperate file for re-usability. Put the code to display the export into a seperate file for re-usability.
* tbl_change.php3, config.inc.php3, libraries/config_import.lib.php3, * tbl_change.php3, config.inc.php3, libraries/config_import.lib.php3,
libraries/common.lib.php3: RFE #422243 - Definition of which MySQL functions libraries/common.lib.php3: RFE #422243 - Definition of which MySQL functions
map to which MySQL field type and in the dropdown of the function list first map to which MySQL field type and in the dropdown of the function list first
display the fitting functions, and then for compatibility reasons the rest of display the fitting functions, and then for compatibility reasons the rest of
the functions. the functions.
TODO: I don't know if I chose the correct mapping for all types. Please correct TODO: I don't know if I chose the correct mapping for all types. Please correct
config_import.lib.php3 and config.inc.php3 if therer are any mismappings. config_import.lib.php3 and config.inc.php3 if therer are any mismappings.
@@ -63,14 +66,14 @@ $Source$
Automatic duplication/moving of PDF pages does not yet work. Would the Automatic duplication/moving of PDF pages does not yet work. Would the
original author please be so kind to have a look at the tbl_move_copy.php original author please be so kind to have a look at the tbl_move_copy.php
script, search for '[TODO]' and apply necessary fixes? ;) script, search for '[TODO]' and apply necessary fixes? ;)
* tbl_dump.php3: New $sql_structure variable for the new table export * tbl_dump.php3: New $sql_structure variable for the new table export
design broke DB export functionality. Fixed this. design broke DB export functionality. Fixed this.
2003-03-12 Marc Delisle <lem9@users.sourceforge.net> 2003-03-12 Marc Delisle <lem9@users.sourceforge.net>
* lang/ukrainian: update, thanks to Markijan Baran * lang/ukrainian: update, thanks to Markijan Baran
2003-03-11 Garvin Hicking <me@supergarv.de> 2003-03-11 Garvin Hicking <me@supergarv.de>
* docSQL/*, read_dump.php3, db_details_importdocsql.php3, * docSQL/*, read_dump.php3, db_details_importdocsql.php3,
libraries/grab_globals.lib.php3, libraries/read_dump.lib.php3: libraries/grab_globals.lib.php3, libraries/read_dump.lib.php3:
Improved security of docSQL importer. You now can only access Improved security of docSQL importer. You now can only access
a subdirectory of phpMyAdmin ('docSQL' proposed) OR upload each a subdirectory of phpMyAdmin ('docSQL' proposed) OR upload each

View File

@@ -160,9 +160,7 @@ unset($tmp_array);
$useBgcolorOne = TRUE; $useBgcolorOne = TRUE;
$countRows = 0; $countRows = 0;
$total = 0;
while (list($name, $value) = each($queryStats)) { while (list($name, $value) = each($queryStats)) {
$total += $value;
?> ?>
<tr> <tr>
<td bgcolor="<?php echo $useBgcolorOne ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']; ?>">&nbsp;<?php echo htmlspecialchars($name); ?>&nbsp;</td> <td bgcolor="<?php echo $useBgcolorOne ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']; ?>">&nbsp;<?php echo htmlspecialchars($name); ?>&nbsp;</td>
@@ -189,7 +187,6 @@ $total += $value;
} }
unset($countRows); unset($countRows);
unset($useBgcolorOne); unset($useBgcolorOne);
$value = $total;
?> ?>
</table> </table>
</td> </td>
@@ -206,10 +203,10 @@ $value = $total;
</tr> </tr>
<tr> <tr>
<td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format($value, 0, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td> <td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format($serverStatus['Questions'], 0, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td>
<td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($value * 3600 / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td> <td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($serverStatus['Questions'] * 3600 / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td>
<td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($value * 60 / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td> <td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($serverStatus['Questions'] * 60 / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td>
<td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($value / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td> <td bgcolor="<?php echo $cfg['BgcolorOne']; ?>" align="right">&nbsp;<?php echo number_format(($serverStatus['Questions'] / $serverStatus['Uptime']), 2, $number_decimal_separator, $number_thousands_separator); ?>&nbsp;</td>
</tr> </tr>
</table> </table>