mirror of
https://github.com/friendica/friendica
synced 2024-11-10 06:22:53 +00:00
Fix GROUP BY for search
https://github.com/friendica/friendica/issues/3322 Fix MySQL ERROR 1055 (42000): Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'friendica.item.author-id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
This commit is contained in:
parent
534ea6aefc
commit
38e7a0f793
1 changed files with 1 additions and 1 deletions
|
@ -214,7 +214,7 @@ function search_content(App $a) {
|
||||||
FROM `item` %s
|
FROM `item` %s
|
||||||
WHERE %s AND (`item`.`uid` = 0 OR (`item`.`uid` = %s AND NOT `item`.`global`))
|
WHERE %s AND (`item`.`uid` = 0 OR (`item`.`uid` = %s AND NOT `item`.`global`))
|
||||||
$sql_extra
|
$sql_extra
|
||||||
GROUP BY `item`.`uri` ORDER BY `item`.`id` DESC LIMIT %d , %d",
|
GROUP BY `item`.`uri`, `item`.`id` ORDER BY `item`.`id` DESC LIMIT %d , %d",
|
||||||
item_fieldlists(), item_joins(), item_condition(),
|
item_fieldlists(), item_joins(), item_condition(),
|
||||||
intval(local_user()),
|
intval(local_user()),
|
||||||
intval($a->pager['start']), intval($a->pager['itemspage']));
|
intval($a->pager['start']), intval($a->pager['itemspage']));
|
||||||
|
|
Loading…
Reference in a new issue