Re: Telling query-time QueryParser how to work by a TokenFilter

2011-06-09 Thread Em
Hi list, if one read line 470 and the following (getFieldQuery) of the queryParser class, one can see, how some attributes are already used to parse the query-string correctly. At the moment, I see almost no chance to implement the wanted behaviour without doing copy & paste on the code for an own

Re: Boosting a document at query time, based on a field value/range

2011-06-09 Thread Erick Erickson
I take it from this that you want documents with values #outside# 20-30 to still be found? In that case you can do something like add a clause like: OR field:[20 TO 30]^10 or similar. Best Erick BTW, is there a reason you decided not to use Solr? In many ways it's easier than straight Lucene...

Boosting a document at query time, based on a field value/range

2011-06-09 Thread Sowmya V.B.
Hi All I have joined the group only today..and began working with lucene only recently. My problem: I want to boost the ranking of certain documents, based on the values of certain fields. For example, if the field has a range of values from 0 to 100 and the user chooses something like 20 to 30

Re: MultiFieldQueryParser with default AND and stopfilter

2011-06-09 Thread Elmer
Thank you Trejkaz! Inspired by your solution I've created the attached extension to the MFQP, a little different than you proposed. In getFieldQuery, if a (stop)word is removed by an analyzer for some field, it will return null, so that term is then ignored (only if using AND as default operator).

RE: Bug fix to contrib/.../IndexSplitter

2011-06-09 Thread Steven A Rowe
Hi Ivan, You do have rights to submit fixes to Lucene - everyone does! Here's how: http://wiki.apache.org/lucene-java/HowToContribute Please create a patch, create an issue in JIRA, and then attach the patch to the JIRA issue. When you do this, you are asked to state that you grant license to

Re: London open source search social - 13th June

2011-06-09 Thread Richard Marr
Just a quick reminder that we're meeting on Monday. Come along if you're around. On 1 June 2011 13:27, Richard Marr wrote: > Hi guys, > > Just to let you know we're meeting up to talk all-things-search on Monday > 13th June. There's usually a good mix of backgrounds and experience levels > so i

Bug fix to contrib/.../IndexSplitter

2011-06-09 Thread Ivan Vasilev
Hi Guys, I would like to fix a class in contrib/misc/src/java/org/apache/lucene/index called IndexSplitter. It has a bug - when splits the segments in separate index the segment descriptor file contains a wrong data - the number (the name) of next segment to generate is 0. Although it can not

RE: Multi value NumericFields - major issue

2011-06-09 Thread Uwe Schindler
I opened an issue to *maybe* store the precision step in index metadata, but this is similar like using a different analyzer on query and index side: https://issues.apache.org/jira/browse/LUCENE-3187 - Uwe Schindler H.-H.-Meier-Allee 63, D-28213 Bremen http://www.thetaphi.de eMail: u...@thetap

RE: Multi value NumericFields - major issue

2011-06-09 Thread Uwe Schindler
Hi, if you pass in a precisionStep != theDefault (which is 4), you also have to pass the same precStep also into the NumericRangeQuery / NumericRangeFilter. If you not do this, you may get too few / incorrect results. This is explained in JavaDocs of NumericRangeQuery. You example does not do this

Multi value NumericFields - major issue

2011-06-09 Thread Tarr, Gregory
The javadocs for NumericField (lucene 2.9.4) state: You may add the same field name as a NumericField to the same document more than once. Range querying and filtering will be the logical OR of all values; so a range query will hit all documents that have at least one value in the range Furthermo

Re: Get all the field names

2011-06-09 Thread Ian Lea
See the javadocs for IndexReader.getFieldNames(IndexReader.FieldOption fldOption). Also see the javadocs for your "Why isn't this correct?" question. Reading Lucene In Action is highly recommended for all people new to lucene. -- Ian. On Thu, Jun 9, 2011 at 9:03 AM, Pranav goyal wrote: > Hi,

Get all the field names

2011-06-09 Thread Pranav goyal
Hi, I want to retrieve all the field names from my index so that I can store them in an array to use in MutiFieldQueryParser. One question can I do it using my index directory? If yes then a piece of code would be really helpful as I searched out a lot but no documentation is there on this thing.