Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 66515 invoked from network); 7 Apr 2005 09:13:00 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Apr 2005 09:13:00 -0000 Received: (qmail 91841 invoked by uid 500); 7 Apr 2005 09:12:51 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 91819 invoked by uid 500); 7 Apr 2005 09:12:51 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Delivered-To: moderator for java-user@lucene.apache.org Received: (qmail 22795 invoked by uid 99); 7 Apr 2005 08:34:37 -0000 X-ASF-Spam-Status: No, hits=1.6 required=10.0 tests=DNS_FROM_RFC_POST,NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) X-VirusChecked: Checked X-Env-Sender: iouli.golovatyi@novartis.com X-Msg-Ref: server-9.tower-84.messagelabs.com!1112862870!8159314!1 X-StarScan-Version: 5.4.12; banners=novartis.com,-,- X-Originating-IP: [160.62.1.169] Subject: Re: Sorting date stored in milliseconds time To: java-user@lucene.apache.org Message-ID: From: iouli.golovatyi@novartis.com Date: Thu, 7 Apr 2005 10:34:29 +0200 MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N well, 1) it would be additional logic overhead to generate the unique id and keep it global for all data providers 2) I doubt that ordering on 2 fields like "time" up to sec (or even to min) and "integer" will be quicker when sorting using just one "long" Scott Farquhar cc: Lucene Users List , (bcc: Iouli Golovatyi/X/GP/Novartis) 06.04.2005 23:51 Subject: Re: Sorting date stored in milliseconds time Please respond to java-user Category: |-------------------------| | ( ) Action needed | | ( ) Decision needed | | ( ) General Information | |-------------------------| On Wed, Apr 06, 2005 at 01:02:35PM +0200, iouli.golovatyi@novartis.com wrote: > I'm forced to keep date up to milisec. The reason is simple: I get at > least a couple of new messages per sec, if all of them are stamped with the > same time, the retrieval order id undefined, i.e. once I get it, let's > say, as the last reference on the first page, other time - as the first one > on the second page. In case You do not keep the cache and always performs > the same query even to get the second page it's getting even worse, i.e. > displaying the messgaes 41-80, may bring the message 41, which You already > displayed on your first page as message 40. Why can't you have a secondary sort on message id? Then you sort by time and message id will always result in consistent ordering. Cheers, Scott -- ATLASSIAN - http://www.atlassian.com Expert J2EE Software, Services and Support ------------------------------------------------------------- JIRA Docs: http://www.atlassian.com/software/jira/docs/latest --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org ______________________________________________________________________ The Novartis email address format has changed to firstname.lastname@novartis.com. Please update your address book accordingly. ______________________________________________________________________ --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org