Forcing lucene to use specific field when processing parsed query

2013-07-06 Thread Puneet Pawaia
terms of the query and change the field ? The given query would be a complex query where there would be spans, clauses etc. Or perhaps there is some way of forcing Lucene to ignore the fields given in the parsed query and used a specified field only. Any help would be most appreciated. Regards Puneet

Re: Forcing lucene to use specific field when processing parsed query

2013-07-06 Thread Puneet Pawaia
Hi Uwe Unfortunately, at the stage I am required to do this, I do not have the query text. I only have the parsed query. I thought of iterating through the query clauses etc but could not find how to. What function allows me to do this ? Regards Puneet Pawaia On 6 Jul 2013 20:06, "Uwe Schi

Re: Forcing lucene to use specific field when processing parsed query

2013-07-06 Thread Puneet Pawaia
Thanks Jack. I had planned on changing the field in the TermQuery or SpanTerm. Unless SpanTerms also drilldown to TermQuery. Only couldn't find the getter method name. Guess I need to look at the docs some more. Regards Puneet Pawaia On 6 Jul 2013 22:38, "Jack Krupansky" wrote

Different results for SpanNear with SpanNot and Boolean Not with SpanNear

2011-09-24 Thread Puneet Pawaia
Hi All, I find that the following 2 queries State NEAR (biha* NOT bihar) which expands to base {Lucene.Net.Search.Query} = {spanNear([contents:state, spanNot(SpanRegexQuery(contents:biha.*), contents:bihar)], 10, False)} (state NEAR biha*) NOT (state NEAR bihar) which expands to base {Lucene.

Different results from combinations of SpanNear with SpanNot and Boolean

2011-09-24 Thread Puneet Pawaia
Hi All, I find that the following 2 queries State NEAR (biha* NOT bihar) which expands to base {Lucene.Net.Search.Query} = {spanNear([contents:state, spanNot(SpanRegexQuery(contents:biha.*), contents:bihar)], 10, False)} (state NEAR biha*) NOT (state NEAR bihar) which expands to base {Lucene.Ne

Getting payloads for query terms of constantscore query

2014-05-19 Thread Puneet Pawaia
Hi I can get the payloads for query terms using getPayloadsForQuery from PayloadSpanUtil. However this does not support ConstantScore queries. So how do I get the payloads for queries that get rewritten to ConstantScore query for example PrefixQuery, WildcardQuery. Thanks Puneet