mirror of
https://github.com/friendica/friendica
synced 2024-11-19 15:03:40 +00:00
Improved query
This commit is contained in:
parent
59cff3511b
commit
71a398277d
1 changed files with 1 additions and 1 deletions
|
@ -181,7 +181,7 @@ class Search extends BaseApi
|
|||
|
||||
$params = ['order' => ['name'], 'limit' => [$offset, $limit]];
|
||||
|
||||
$condition = ["`id` IN (SELECT `tid` FROM `post-tag` WHERE `type` = ? AND `tid` = `id`) AND `name` LIKE ?", Tag::HASHTAG, $q . '%'];
|
||||
$condition = ["EXISTS(SELECT `tid` FROM `post-tag` WHERE `type` = ? AND `tid` = `id`) AND `name` LIKE ?", Tag::HASHTAG, $q . '%'];
|
||||
|
||||
$tags = DBA::select('tag', ['name'], $condition, $params);
|
||||
|
||||
|
|
Loading…
Reference in a new issue