Filtering accents

2008-12-30 Thread legrand thomas
Dear all, I'd like my lucene searches to be insensitive to (French) accents. For example, considering a indexed term "métal", I want to get it when searching for "metal" or "métal" . I use lucene-2.3.2 and the searches are performed with: IndexSearcher.search(query,filter,sorter), Another filte

Index and search terms containing character "-"

2009-05-31 Thread legrand thomas
Hi, I have a problem using TermQuery and FuzzyQuery for terms containing the character "-". Considering I've indexed "jack" and "jack-bauer" as 2 tokenized captions, I get no result when searching for "jack-bauer". Moreover, "jack" with a TermQuery returns the two captions.   What should I do t

Re: Index and search terms containing character "-"

2009-06-02 Thread legrand thomas
d strongly recommend you get a copy of Luke, it's invaluable for questions like this because it lets you look at what's actually in your index. It'll also show you how queries get broken down when pushed through various analyzers... BTW, nice test case for demonstrating what you w

Date sorting problem [ IndexSearcher | Hits | Sort | Float ]

2008-03-08 Thread legrand thomas
Dear all, I'm trying to sort query results using a date criteria. My dates are stored as "long" in the database (I cannot change this) and indexed as untokenized. The sorted resuIts I get aren't consistent. This problem does not occur if the number are "smaller". Am I doing something wrong ? I

Search for long titles - wildcard queries

2008-05-10 Thread legrand thomas
Dear all, I'm a recent Lucene user and I'm looking for the best way to perform searches over long titles (ad titles on a website). For example, if the following documents exist: - TITLE, "Fender telecaster" - TITLE, "Land rover defender" - TITLE, "I sale a wonderful fender st

advanced WildcardQuery

2008-07-16 Thread legrand thomas
Dear all, I'd like to search on long titles (tokenized and stored) using the WildcardQuery. Considering the following example: title="pretty car for sale" If I search for "pretty*", I get the document having this title. But it's not the case if I build a WilcardQuery with the term "pretty*ca

Concurrent access IndexReader / IndexWriter - FileNotFoundException

2010-01-08 Thread legrand thomas
Hi, I often get a FileNotFoundException when my single IndexWriter commits while the IndexReader also tries to read. My application is multithreaded (Tomcat uses the business APIs); I firstly thought the read/write access was thread-safe but I probably forget something.  Please help me to unde

Re: Concurrent access IndexReader / IndexWriter - FileNotFoundException

2010-01-09 Thread legrand thomas
xWriter is committing) is perfectly fine.  The reader searches the point-in-time snapshot of the index as of when it was opened. But: what filesystem are you using?  NFS presents challenges, for example. Mike On Fri, Jan 8, 2010 at 5:35 AM, legrand thomas wrote: > Hi, > > I often get a Fi

Re: Concurrent access IndexReader / IndexWriter - FileNotFoundException

2010-01-09 Thread legrand thomas
McCandless a écrit : De: Michael McCandless Objet: Re: Concurrent access IndexReader / IndexWriter - FileNotFoundException À: java-user@lucene.apache.org Date: Samedi 9 Janvier 2010, 14h51 Can you post the full FNFE stack trace? Mike On Fri, Jan 8, 2010 at 5:35 AM, legrand thomas wrote: >

Re: Concurrent access IndexReader / IndexWriter - FileNotFoundException

2010-01-09 Thread legrand thomas
ginal questions...: commit/read does not require any external synchronization or locking.  You should generally keep your IW open indefinitely and just periodically commit and/or get a new reader (IndexWriter.getReader()) as needed. Mike On Sat, Jan 9, 2010 at 10:06 AM, legrand thomas wrote: > &g

Help IndexWriter,Multi-threaded index access

2007-05-11 Thread legrand thomas
Hello, I work on a web application deployed on a Tomcat server 5. Many jsp front pages (thanks to controllers) query a single manager (retrieved by a factory as an instance). This manager deals with Lucene index, stored by using a FSDirectory, to create several kind of documents, append or rem

Help IndexWriter,Multi-threaded index access

2007-05-11 Thread legrand thomas
Hello, I work on a web application deployed on a Tomcat server 5. Many jsp front pages (thanks to controllers) query a single manager (retrieved by a factory as an instance). This manager deals with Lucene index, stored by using a FSDirectory, to create several kind of documents, append or rem