I don't think lucene will support multi sort. If you look into org.apache.lucene.search.TopScoreDocCollector you may get some feeling. It use max heap to sort the document, and the score is one time calculate, it it not first sort by time, then sort again by id.
When lucene sort below documents: record_1 201207170101 record_2 201207170101 record_3 201207170102 record_4 201207170102 first get record_1, and it score is 201207170101, then record_1 on top of the heap tehn get record_2, and it score is 201207170101, then will put record_2 after record_1 then get record_3, and it score is 201207170102, this score > current top value 201207170101, then the max heap change to record_3, record_1, record_2 last get record_3, and it score is 201207170102, is score = current top male 201207170102, , then the max heap change to record_3, record_4, record_1, record_2 -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-sort-field-tp3995502p3995699.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org