Query language: it used to be that an entry lacking whitespace but
splittable, like [term1,term2] was transformed into a phrase search, which made sense in some cases, but no so many. This commit changes this: [term1,term2] now means term1 AND term2. [term1/term2] means term1 OR term2. This is especially useful for field searches where you would previously be forced to repeat the field name for every term. [somefield:term1 somefield:term2] can now be expressed as somefield:term1,term2
This commit is contained in:
@@ -255,10 +255,6 @@ bool SSearch::startSimpleSearch(const string& u8, int maxexp)
|
||||
Rcl::SearchDataClause *clp = 0;
|
||||
if (tp == SST_FNM) {
|
||||
clp = new Rcl::SearchDataClauseFilename(u8);
|
||||
} else if (!TextSplit::hasVisibleWhite(u8)) {
|
||||
// If there is no white space inside the query, then the user
|
||||
// certainly means it as a phrase.
|
||||
clp = new Rcl::SearchDataClauseDist(Rcl::SCLT_PHRASE, u8, 0);
|
||||
} else {
|
||||
// ANY or ALL, several words.
|
||||
if (tp == SST_ANY) {
|
||||
|
||||
Reference in New Issue
Block a user