Don't prefix queries get rewritten wrapped in ConstantScoreQuery,
meaning all will get the same score and you get them in read order?
Checking the API, PrefixQuery uses
MultiTermQuery.CONSTANT_SCORE_AUTO_REWRITE_DEFAULT, which can be changed
with setRewriteMethod. 

-----Original Message-----
From: Ian Lea [mailto:ian....@gmail.com] 
Sent: 01 April 2011 15:55
To: java-user@lucene.apache.org
Subject: Re: About the lucene sort

Probably a bug in your code.

If you post again with, as a minimum, the version of lucene that you are
using and your search/sort code, you might get a better answer.
Best of all would be a complete self-contained standalone program or
test case that demonstrates the problem.


--
Ian.


On Fri, Apr 1, 2011 at 3:15 PM, Cescky <ee07b...@gmail.com> wrote:
> Hi,
>
>
> I know the default is sort by relevance. While, when i search the
prefix (interface*), it does not work. It can only sort the document by
the order of reading files.
>
>
> What is the problem???
>
>
> Thx.

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

Please consider the environment before printing this email.

This message should be regarded as confidential. If you have received this 
email in error please notify the sender and destroy it immediately.
Statements of intent shall only become binding when confirmed in hard copy by 
an authorised signatory.  The contents of this email may relate to dealings 
with other companies within the Detica Limited group of companies.

Detica Limited is registered in England under No: 1337451.

Registered offices: Surrey Research Park, Guildford, Surrey, GU2 7YP, England.


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

Reply via email to