lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From René Ferréro <rene_ferr...@yahoo.fr>
Subject Query with stop word + AND operand : java.lang.ArrayIndexOutOfBoundsException
Date Sun, 23 Mar 2003 21:03:05 GMT
Hi,
1- If a stop word is the first term of AND operator,
ArrayIndexOutOfBounsException is raised.

The word "use" being in my stopword list, the query
below fails :

		QueryParser parser = new QueryParser("contents",
specific_analyzer_with_stopword) ; 
		Query query = parser.parse("use AND case");

java.lang.ArrayIndexOutOfBoundsException: -1 < 0
	at java.util.Vector.elementAt(Vector.java:437)
	at
org.apache.lucene.queryParser.QueryParser.addClause(QueryParser.java:161)
	at
org.apache.lucene.queryParser.QueryParser.Query(QueryParser.java:463)
	at
org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:113)
	at
mypackage.test.TestLuceneSearch.search(TestLuceneSearch.java:224)

2- On the other hand, when I permute the stop word
after the 'AND' operator as : "case AND use", the
query works well.

Does anybody go through this kind of issue  before ?
Is this a bug or is it some limitation, where lucene
required very strict rules on well formed query string
?
Thanks.

___________________________________________________________
Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français !
Yahoo! Mail : http://fr.mail.yahoo.com

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


Mime
View raw message