search for: default_op

Displaying 6 results from an estimated 6 matches for "default_op".

2011 Dec 14
1
How to enable stemming with default_op set to OP_NEAR
Hi All, I know that from version 1.2.6, if default_op is OP_NEAR or OP_PHRASE then stemming of the terms is disabled, since positional information isn't indexed for stemmed terms by default. However, I would like to try using OP_NEAR as default_op with stemming because I think the near operator is somehow different from exact phrase. Then I wanna...
2011 May 27
1
Does OP_NEAR works with stemming?
Hi All, I used the OP_NEAR operator for queryparser, and when I searched for "apple store" from my own collection, the query is parsed as "Zappl:(pos=1) NEAR 11 Zstore:(pos=2)" but retrieved nothing. However, if I type in "Apple Store", the query is parsed as Xapian::Query((apple:(pos=1) NEAR 11 store:(pos=2))) and some results are showed. I'm not sure whether
2009 Dec 13
1
Combined search in multiple fields help
...h resulting Xapian::Query by get_terms and apend A or S prefix to evey term (after Z if Z is present, and not appending where other prefix is already applied (for example H)). (Btw, is this optimal strategy?) What I think about multiple fields and where it fail: There is two situation depending on default_op(). 'or') I just duplicate parsed query as whole and add different prefix to each of them, then combine these big queries with 'or'. 'and') hard part begin, probably I should duplicate each term, add one prefix to original and other to clone and combine it with OR with existi...
2008 Sep 16
0
[PATCH] Add set_max_wildcard_expansion method to the queryparser.
...t string &field, const string &prefix, bool filter); std::string parse_term(Utf8Iterator &it, const Utf8Iterator &end, @@ -81,7 +83,7 @@ class QueryParser::Internal : public Xapian::Internal::RefCntBase { public: Internal() : stem_action(STEM_NONE), stopper(NULL), - default_op(Query::OP_OR), errmsg(NULL) { } + default_op(Query::OP_OR), errmsg(NULL) { max_wildcard_expansion=0; } Query parse_query(const string & query_string, unsigned int flags, const string & default_prefix); }; -- 1.5.6.3 --=-=-=--
2010 Jan 19
1
QueryParser: aliases and OP_AND
...o, I'm wondering about how the QueryParser parses a query containing an "alias" when the default operator is OP_AND (by "alias", I mean a search field mapped to multiple term prefixes). With the following php code : <?php $parser=new XapianQueryParser(); $parser->set_default_op(XapianQuery::OP_AND); $parser->add_prefix('alias', 'AUT1:'); $parser->add_prefix('alias', 'AUT2:'); echo $parser->parse_query('alias:(john smith)')->get_description(); ?> I get: Xapian::Query(((AUT1:john:(pos=1) OR AUT2:john:(pos=1)) AND (AUT...
2012 Jan 05
1
Enhance synonyms feature of the query parser (patch included)
...else sterm = *piter + sterm; + } + q = Query(query::OP_SYNONYM, q, Query(sterm, 1, pos)); + #else q = Query(Query::OP_SYNONYM, q, Query(*syn, 1, pos)); + #endif ++syn; } } *************** *** 1356,1362 **** --- 1369,1379 ---- Query::op default_op = state->default_op(); vector<Query> subqs; subqs.reserve(terms.size()); + #ifdef HAVE_SYNONYMS_ENH + if ((state->flags & QueryParser::FLAG_AUTO_MULTIWORD_SYNONYMS) == QueryParser::FLAG_AUTO_MULTIWORD_SYNONYMS) { + #else if (state->flags & QueryParser::F...