lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gsanctus <gsa...@pitagora.it>
Subject Span Query on different fields
Date Tue, 18 Sep 2007 17:22:39 GMT

Hello,
I have an index with tree fields (field1, field2,field3).
I have to do an or-query and get term positions within a document.
So I'm using span query but I have a problem because
with spans I can't write
...
SpanTermQuery field1 = new SpanTermQuery(new Term("field1", "hello"));
SpanTermQuery field2 = new SpanTermQuery(new Term("field2", "hello"));
SpanTermQuery field3 = new SpanTermQuery(new Term("field3", "hello"));
SpanOrQuery or = new SpanOrQuery(new SpanQuery[] {field1, field2,field3});
With this code I get an error because SpanOrQuery Clauses must have same
field.

My question is:
Is defined a field positions iterator on Spans or other structure ???

Can you help me???

Thanks
-- 
View this message in context: http://www.nabble.com/Span-Query-on-different-fields-tf4475788.html#a12761926
Sent from the Lucene - Java Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message