Merge pull request #2483 from k9mail/fts-uncorrelated-subquery
use uncorrelated subquery for fts search term
This commit is contained in:
commit
009b40ccad
1 changed files with 1 additions and 1 deletions
|
@ -80,7 +80,7 @@ public class SqlQueryBuilder {
|
||||||
if (condition.attribute != Attribute.CONTAINS) {
|
if (condition.attribute != Attribute.CONTAINS) {
|
||||||
Timber.e("message contents can only be matched!");
|
Timber.e("message contents can only be matched!");
|
||||||
}
|
}
|
||||||
query.append("(EXISTS (SELECT docid FROM messages_fulltext WHERE docid = id AND fulltext MATCH ?))");
|
query.append("m.id IN (SELECT docid FROM messages_fulltext WHERE fulltext MATCH ?)");
|
||||||
selectionArgs.add(fulltextQueryString);
|
selectionArgs.add(fulltextQueryString);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue