mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-08 12:28:52 +00:00
Merge pull request #5076 from marc1706/ticket/15496
[ticket/15496] Add sort key to SELECT in fulltext_postgres
This commit is contained in:
commit
f26b2c00de
1 changed files with 1 additions and 1 deletions
|
@ -498,7 +498,7 @@ class fulltext_postgres extends \phpbb\search\base
|
||||||
);
|
);
|
||||||
extract($this->phpbb_dispatcher->trigger_event('core.search_postgres_keywords_main_query_before', compact($vars)));
|
extract($this->phpbb_dispatcher->trigger_event('core.search_postgres_keywords_main_query_before', compact($vars)));
|
||||||
|
|
||||||
$sql_select = ($type == 'posts') ? 'p.post_id' : 'DISTINCT t.topic_id';
|
$sql_select = ($type == 'posts') ? 'p.post_id' : 'DISTINCT t.topic_id, ' . $sort_by_sql[$sort_key];
|
||||||
$sql_from = ($join_topic) ? TOPICS_TABLE . ' t, ' : '';
|
$sql_from = ($join_topic) ? TOPICS_TABLE . ' t, ' : '';
|
||||||
$field = ($type == 'posts') ? 'post_id' : 'topic_id';
|
$field = ($type == 'posts') ? 'post_id' : 'topic_id';
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue