#2002 error in query statement in lib/wiki/wikilib.php

open
nobody
None
5
2012-12-08
2005-11-20
Edward Pilipczuk
No

line 596 of lib/wiki/wikilib.php (sirius 1.9.2/3) is

$query = "select distinct(p.`pageName`), p.`user` as
lastEditor, p.`creator`, max(a.`lastModif`) as date
from `tiki_actionlog` as a, `tiki_pages` as p where
a.`pageName`= p.`pageName` and a.`user`= ? group by
p.`pagename` asc order by
".$this->convert_sortmode($sort_mode);

should be:

$query = "select distinct(p.`pageName`), p.`user` as
lastEditor, p.`creator`, max(a.`lastModif`) as date
from `tiki_actionlog` as a, `tiki_pages` as p where
a.`pageName`= p.`pageName` and a.`user`= ? group by
p.`pageName`,p.`user`,p.`creator` order by
".$this->convert_sortmode($sort_mode);

Discussion