RegexQuery on multiple fields?

2007-10-04 Thread Oliver Hummel
Hi, I've recently tried the RegexQuery with Lucene which works fine with the following code snippet: Hits hits; String q = "someregex"; Term t = new Term("content", q); Query query = new RegexQuery(t); hits = searcher.search(query); However, I wonder whether it is possible to use a Que

Re: Strange Behaviour of BooleanQuery?

2007-02-08 Thread Oliver Hummel
Eric, thanks for your reply. > I assume it's a typo, but your for loop wouldn't produce your example as > they'd all be the same field Actually there are three loops that add it for different fields... :-) > So, here's what I'd do. Use Query.toString() for both your BooleanQuery and > the qu

Strange Behaviour of BooleanQuery?

2007-02-08 Thread Oliver Hummel
Hi @all, I'm a little confused about the behaviour of BooleanQuery. I have a custom parser that analyzes some text and constrcuts an "ANDed" BooleanQuery. toString delivers something like this: (+field1:term1 +field2:term2) Looks pretty normal to me, but the problem is it delivers no results (