[PHP-BUG] Bug #55666 [NEW]: mysql_stat says questions but outputs queries information_schema.global_statu
From: Operating system: LINUX PHP version: 5.3SVN-2011-09-10 (SVN) Package: MySQL related Bug Type: Bug Bug description:mysql_stat says questions but outputs queries information_schema.global_statu Description: PHP 5.3.5 / MySQL 5.5.8 / XAMPP 1.7.4 for LINUX MySQL maintains two variables in information_schema.global_status: QUERIES and QUESTIONS. mysql_stat throws QUESTIONS but displays variable QUERIES. Problem has also been around in PHP 5.1 Test script: --- from php.net documentation Array ( [0] => Uptime: 5380 [1] => Threads: 2 [2] => Questions: 1321299 [3] => Slow queries: 0 [4] => Opens: 26 [5] => Flush tables: 1 [6] => Open tables: 17 [7] => Queries per second avg: 245.595 ) Expected result: [2] => Queries: 1321299 -- Edit bug report at https://bugs.php.net/bug.php?id=55666&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=55666&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=55666&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=55666&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=55666&r=fixed Fixed in SVN and need be documented: https://bugs.php.net/fix.php?id=55666&r=needdocs Fixed in release: https://bugs.php.net/fix.php?id=55666&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=55666&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=55666&r=needscript Try newer version: https://bugs.php.net/fix.php?id=55666&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=55666&r=support Expected behavior: https://bugs.php.net/fix.php?id=55666&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=55666&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=55666&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=55666&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=55666&r=php4 Daylight Savings:https://bugs.php.net/fix.php?id=55666&r=dst IIS Stability: https://bugs.php.net/fix.php?id=55666&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=55666&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=55666&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=55666&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=55666&r=mysqlcfg
Bug #55666 [Bgs]: mysql_stat says questions but outputs queries information_schema.global_statu
Edit report at https://bugs.php.net/bug.php?id=55666&edit=1 ID: 55666 User updated by:linuxaomi at operamail dot com Reported by:linuxaomi at operamail dot com Summary:mysql_stat says questions but outputs queries information_schema.global_statu Status: Bogus Type: Bug Package:MySQL related Operating System: LINUX PHP Version:5.3SVN-2011-09-10 (SVN) Block user comment: N Private report: N New Comment: Hello Johannes, please be more specific. Which chapter/sentence of the mentioned URLs I am supposed to read? I also cannot see what went wrong reporting this discrepancy. As a matter of fact MySQL just provides two fields with individual fieldnames and contents. PHP reports FIELDA: content(FIELDB) rather than FIELDA: content(FIELDA) or FIELDB: content(FIELDB). Can you comprehend? Best regards, linuxaomi Previous Comments: [2011-09-25 13:21:12] johan...@php.net Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php This is the behavior of libmysql to which PHP and mysqlnd are compatible. See http://dev.mysql.com/doc/refman/5.5/en/mysql-stat.html and http://dev.mysql.com/doc/refman/5.5/en/mysqladmin.html If you want this to be changed report this as abug to MySQL/Oracle. [2011-09-10 16:17:54] linuxaomi at operamail dot com Description: PHP 5.3.5 / MySQL 5.5.8 / XAMPP 1.7.4 for LINUX MySQL maintains two variables in information_schema.global_status: QUERIES and QUESTIONS. mysql_stat throws QUESTIONS but displays variable QUERIES. Problem has also been around in PHP 5.1 Test script: --- from php.net documentation Array ( [0] => Uptime: 5380 [1] => Threads: 2 [2] => Questions: 1321299 [3] => Slow queries: 0 [4] => Opens: 26 [5] => Flush tables: 1 [6] => Open tables: 17 [7] => Queries per second avg: 245.595 ) Expected result: [2] => Queries: 1321299 -- Edit this bug report at https://bugs.php.net/bug.php?id=55666&edit=1