Public bug reported:

1) The release of Ubuntu you are using, via 'lsb_release -rd' or System -> 
About Ubuntu
Ubuntu 16.04.6 LTS

2) The version of the package you are using, via 'apt-cache policy
pkgname' or by checking in Software Center

phpmyadmin:
  Installed: 4:4.5.4.1-2ubuntu2.1
  Candidate: 4:4.5.4.1-2ubuntu2.1
  Version table:
 *** 4:4.5.4.1-2ubuntu2.1 500
        500 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 
Packages
        500 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 
Packages
        100 /var/lib/dpkg/status
     4:4.5.4.1-2ubuntu1 500
        500 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages

3) What you expected to happen

Any table is opened from any database. The rows from table should be
listed on PHPMyadmin display.

4) What happened instead

An error pop-up appears: "Some errors have been detected on the server!
Please look at the bottom of this window." (Ignore All) (Ignore)

The detailed error is:

Warning in ./libraries/sql.lib.php#601
 count(): Parameter must be an array or an object that implements Countable

Backtrace

./libraries/sql.lib.php#2038: PMA_isRememberSortingOrder(array)
./libraries/sql.lib.php#1984: PMA_executeQueryAndGetQueryResponse(
array,
boolean true,
string 'mailserver',
string 'virtual_aliases',
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
string '',
string './themes/pmahomme/img/',
NULL,
NULL,
NULL,
string 'SELECT * FROM `virtual_aliases`',
NULL,
NULL,
)
./sql.php#216: PMA_executeQueryAndSendQueryResponse(
array,
boolean true,
string 'mailserver',
string 'virtual_aliases',
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
string '',
string './themes/pmahomme/img/',
NULL,
NULL,
NULL,
string 'SELECT * FROM `virtual_aliases`',
NULL,
NULL,
)

This error can be corrected by editing file
/usr/share/phpmyadmin/libraries/sql.lib.php as follows:

line 601:
Replace || count($analyzed_sql_results['select_expr'] == 1)
With || (count($analyzed_sql_results['select_expr']) == 1)

line 602:
Replace && ($analyzed_sql_results['select_expr'][0] == '*')))
With && ($analyzed_sql_results['select_expr'][0] == '*'))

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: phpmyadmin 4:4.5.4.1-2ubuntu2.1
Uname: Linux 2.6.32-042stab140.1 x86_64
ApportVersion: 2.20.1-0ubuntu2.21
Architecture: amd64
Date: Thu Nov 14 08:34:19 2019
PackageArchitecture: all
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 SHELL=/bin/bash
SourcePackage: phpmyadmin
UpgradeStatus: No upgrade log present (probably fresh install)
mtime.conffile..etc.phpmyadmin.apache.conf: 2019-09-15T12:07:25.653028

** Affects: phpmyadmin (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug third-party-packages xenial

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1852536

Title:
  Warning in ./libraries/sql.lib.php shown, when any table contents are
  listed

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/phpmyadmin/+bug/1852536/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to