lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 32167] - [PATCH]multiple wildcards ? at the end of search pattern return incorrect hits
Date Sat, 13 Nov 2004 17:17:26 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=32167>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=32167

[PATCH]multiple wildcards ? at the end of search pattern return incorrect hits

xiaozheng.ma@redwood.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary| [PATCH]multiple wildcards ?|[PATCH]multiple wildcards ?
                   |at the end of search pattern|at the end of search pattern
                   |return incorrect hits       |return incorrect hits



------- Additional Comments From xiaozheng.ma@redwood.com  2004-11-13 17:17 -------
for unit test:

In testQuestionmark of TestWildcardQuery.java, The original unit test assetions
(for query 2 and query3) should change to pass the test. Since previously 
the 'metal' matches 'metal?', but it should not.

changes for quert2's assertion:
	assertMatches(searcher, query2, 1); 
	// note that the number changes to
        // 1 since 'metal' is not a match any more.
The same modification to query3's assertion is :
		assertMatches(searcher, query3, 0); 
		//change to 0 since there is no match

Erik has suggest a new unit test:

         Query query6 = new WildcardQuery(new Term("body", "metal??"));
         assertMatches(searcher, query6, 0);

After I review this bug carefully, I realize that the bug is not only for 
multiply '?', it is for trail "?"-- After all "?" is not a "*"

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


Mime
View raw message