lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "rcolmegna (JIRA)" <j...@apache.org>
Subject [jira] Created: (LUCENE-597) Strange results
Date Sat, 10 Jun 2006 15:46:29 GMT
Strange results
---------------

         Key: LUCENE-597
         URL: http://issues.apache.org/jira/browse/LUCENE-597
     Project: Lucene - Java
        Type: Test

    Versions: 2.0.0    
 Environment: jdk 5
    Reporter: rcolmegna


I noted that these queris give different results.  But they are the same logical query (or
I'm in error?) !

-------------------- 1---------------------------- (5 results)
BooleanQuery query = new BooleanQuery();
WildcardQuery subq1 = new WildcardQuery(new Term("dest","test*"));
WildcardQuery subq2 = new WildcardQuery(new Term("dest","try*"));
BooleanQuery bsubq2 = new BooleanQuery();
WildcardQuery subq3 = new WildcardQuery(new Term("dest","12345*"));
query.add(subq1, BooleanClause.Occur.MUST);
query.add(subq2, BooleanClause.Occur.MUST);
bsubq2.add(subq3, BooleanClause.Occur.MUST);
query.add(bsubq2, BooleanClause.Occur.MUST_NOT);

-------------------- 2---------------------------- (no results)
BooleanQuery query = new BooleanQuery();
WildcardQuery subq1 = new WildcardQuery(new Term("dest","test*"));
WildcardQuery subq2 = new WildcardQuery(new Term("dest","try*"));
BooleanQuery bsubq2 = new BooleanQuery();
WildcardQuery subq3 = new WildcardQuery(new Term("dest","12345*"));
query.add(subq1, BooleanClause.Occur.MUST);
query.add(subq2, BooleanClause.Occur.MUST);
bsubq2.add(subq3, BooleanClause.Occur.MUST_NOT);    // difference against 1st query
query.add(bsubq2, BooleanClause.Occur.MUST);   // difference against 1st query

Any suggests?

TIA
Roberto Colmegna


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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


Mime
View raw message