lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ferdinand Chan" <ferdinand.c...@dcivision.com>
Subject RE: Questions on Query Scorer
Date Thu, 15 Jun 2006 10:07:34 GMT
Thanks Mile,

But in my code, I haven't query the term prohibited. Also, in my index,
there isn't a field called prohibited

-----Original Message-----
From: Mile Rosu [mailto:mile.rosu@level7.ro] 
Sent: Thursday, June 15, 2006 5:44 PM
To: java-user@lucene.apache.org
Subject: RE: Questions on Query Scorer

Hello,

The problem may be rather in the name of the field you are querying -
"prohibited" in your case. 
You can check with Luke(http://www.getopt.org/luke/) the structure of
the index on which you are performing your query.

Mile

-----Original Message-----
From: Ferdinand Chan [mailto:ferdinand.chan@dcivision.com] 
Sent: Thursday, June 15, 2006 12:26 PM
To: java-user@lucene.apache.org
Subject: Questions on Query Scorer

How can I create a QueryScorer in Lucene 2.0???

 

When I create a QueryScorer using the following codes,

 

BooleanQuery booleanQuery = new BooleanQuery();

booleanQuery.add(q1,BooleanClause.Occur.SHOULD);

booleanQuery.add(q2,BooleanClause.Occur.SHOULD);

 

QueryScorer scorer = new QueryScorer(booleanQuery);

 

It compiles successfully but throws a runtime exception when I execute
the
code.

 

java.lang.NoSuchFieldError: prohibited

        at
org.apache.lucene.search.highlight.QueryTermExtractor.getTermsFromBoolea
nQue
ry(QueryTermExtractor.java:91)

        at
org.apache.lucene.search.highlight.QueryTermExtractor.getTerms(QueryTerm
Extr
actor.java:66)

        at
org.apache.lucene.search.highlight.QueryTermExtractor.getTerms(QueryTerm
Extr
actor.java:59)

        at
org.apache.lucene.search.highlight.QueryTermExtractor.getTerms(QueryTerm
Extr
actor.java:45)

        at
org.apache.lucene.search.highlight.QueryScorer.<init>(QueryScorer.java:4
8)

 

Can anyone suggest a solution to this problem?

 

Thanks

 

Ferdinand

 


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



---------------------------------------------------------------------
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