Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 8543 invoked from network); 13 Jun 2007 13:07:41 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 13 Jun 2007 13:07:41 -0000 Received: (qmail 84269 invoked by uid 500); 13 Jun 2007 13:07:31 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 84236 invoked by uid 500); 13 Jun 2007 13:07:31 -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 Received: (qmail 84217 invoked by uid 99); 13 Jun 2007 13:07:31 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Jun 2007 06:07:31 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: local policy) Received: from [132.210.244.93] (HELO smtpi2.usherbrooke.ca) (132.210.244.93) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Jun 2007 06:07:27 -0700 Received: from [192.168.1.13] ([132.210.142.98]) by smtpi2.usherbrooke.ca (8.13.1/8.13.1) with ESMTP id l5DD6s4Y013585 for ; Wed, 13 Jun 2007 09:06:55 -0400 Message-ID: <466FEBEE.4020204@usherbrooke.ca> Date: Wed, 13 Jun 2007 09:06:54 -0400 From: Patrick Turcotte User-Agent: Thunderbird 2.0.0.0 (Windows/20070326) MIME-Version: 1.0 To: java-user@lucene.apache.org Subject: Re: How to implement AJAX search~Lucene Search part? References: <6e3ae6310706071831s6e2b239as77bcbbc39e47548f@mail.gmail.com> <4669521F.7050101@usherbrooke.ca> <30B18185-E382-4DF7-A0A1-FA3AD811F7EE@garambrogne.net> In-Reply-To: <30B18185-E382-4DF7-A0A1-FA3AD811F7EE@garambrogne.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-UdeS-MailScanner-Information: Veuillez consulter le http://www.usherbrooke.ca/vers/virus-courriel X-UdeS-MailScanner: Aucun code suspect =?ISO-8859-1?Q?d=E9tect=E9?= X-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-2.499, requis 5, BAYES_00 -2.60, RDNS_NONE 0.10) X-UdeS-MailScanner-From: patrick.turcotte@usherbrooke.ca X-Virus-Checked: Checked by ClamAV on apache.org Thanks Mathieu! Didn't realise this was avalaible before you mentioned it. Did comparative tests, and it is as fast or much faster, thanks to caching, depending on the length of the prefix. Hey, it even works with wildcard within the "search string". Thanks again! Isn't Lucene wonderful! Patrick Mathieu Lecarme wrote: > If you do that, you enumerate every terms!!! > If you use a alphabeticaly sorted collection, you can stop, when match > stop, but, you have to test every terms before matching. > Lucene gives you tools to match begining of a term, just use it!! > > M. > Le 8 juin 07 =E0 14:57, Patrick Turcotte a =E9crit : > >> Hi, >> >> What we did was this: >> >> 1) When you application starts, it scans the index for terms values an= d >> store them in a map or something. >> >> 2) When you receive "ajax requests", you compare with the map data and= >> return the relevant part. Works quite fast for us, without round trips= >> to Lucene. >> >> Patrick --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org