Skip to content

Commit

Permalink
[xelfinder_db] fix #11 stricter “group by” to support MySQL 5.7
Browse files Browse the repository at this point in the history
  • Loading branch information
nao-pon committed Nov 5, 2019
1 parent 03d0d33 commit 457892e
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -727,7 +727,7 @@ protected function cacheDir($path) {
FROM '.$this->tbf.' AS f
LEFT JOIN '.$this->tbf.' AS ch ON ch.parent_id=f.file_id AND ch.mime="directory"
WHERE f.parent_id="'.$path.'"
GROUP BY f.file_id';
GROUP BY f.file_id, f.parent_id, f.name, f.size, f.mtime, f.mime, f.perm, f.umask, f.uid, f.gid, f.home_of, f.width, f.height, f.gids, f.mime_filter, f.local_path, ch.file_id';

$res = $this->query($sql);
if ($res) {
Expand Down Expand Up @@ -1044,7 +1044,7 @@ protected function _stat($path, $rootCheck = true) {
LEFT JOIN '.$this->tbf.' AS p ON p.file_id=f.parent_id
LEFT JOIN '.$this->tbf.' AS ch ON ch.parent_id=f.file_id AND ch.mime="directory"
WHERE f.file_id="'.$path.'"
GROUP BY f.file_id';
GROUP BY f.file_id, f.parent_id, f.name, f.size, f.mtime, f.mime, f.perm, f.umask, f.uid, f.gid, f.home_of, f.width, f.height, f.gids, f.mime_filter, f.local_path, ch.file_id';

$res = $this->query($sql);

Expand Down

0 comments on commit 457892e

Please sign in to comment.