Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 93497 invoked from network); 17 Jan 2007 21:10:20 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 17 Jan 2007 21:10:20 -0000 Received: (qmail 51086 invoked by uid 500); 17 Jan 2007 21:10:15 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 51061 invoked by uid 500); 17 Jan 2007 21:10:15 -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 51050 invoked by uid 99); 17 Jan 2007 21:10:15 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Jan 2007 13:10:15 -0800 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of erickerickson@gmail.com designates 66.249.92.171 as permitted sender) Received: from [66.249.92.171] (HELO ug-out-1314.google.com) (66.249.92.171) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Jan 2007 13:10:06 -0800 Received: by ug-out-1314.google.com with SMTP id k40so4017ugc for ; Wed, 17 Jan 2007 13:09:45 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=E9J83yqB5tJz5EkKykPwUDCoqE0dD6ojuS5gNxk5iSBK3q7F2A5uLTZ1HCTfQNFB173gbXFUK/+Z65+NpMxbE7w9g8APV37CjTSZiqB5p4qp10dVgJHJ7aj08CptPmWaj+wj7WkrK4MNAg8nTP76i3oQSpomH+eRNhbgf2wiVVw= Received: by 10.82.139.17 with SMTP id m17mr1646951bud.1169068184523; Wed, 17 Jan 2007 13:09:44 -0800 (PST) Received: by 10.82.162.9 with HTTP; Wed, 17 Jan 2007 13:09:44 -0800 (PST) Message-ID: <359a92830701171309p1285387et6705da08f11fb7ee@mail.gmail.com> Date: Wed, 17 Jan 2007 16:09:44 -0500 From: "Erick Erickson" To: java-user@lucene.apache.org Subject: Re: sorting issue with un-tokenized field In-Reply-To: <8418521.post@talk.nabble.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_132293_643903.1169068184478" References: <8418417.post@talk.nabble.com> <8418521.post@talk.nabble.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_132293_643903.1169068184478 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline I'd look at a couple of things: 1> are you absolutely sure you didn't store bookTitles more than once? i.e. doc = new DOcument(); doc.add(new Term("bookTitles", .....)); doc.add(new Term("bookTitles", .....)); writer.add(doc); 2> When you built your index, did you append to an old one or replace it? I'm wondering if you have what you think you do in your index (you can look with Luke )... 3> If you're really stuck, you could use termdocs/termenum to count your terms and see what document has more than one entry and try to work backwards. Hope this helps Erick On 1/17/07, moraleslos wrote: > > > Oops, accidently pressed the ENTER key before doing anything ;-) > > I have a field called "bookTitle" that I specified as UN_TOKENIZED and > STORED in the index (i.e. keyword). However, when I do a sort on this > field > during a search I get this error: > > Exception occurred during search: java.lang.RuntimeException: there are > more > terms than documents in field "bookTitles", but it's impossible to sort on > tokenized fields > > My gut feeling on this is that some of my "bookTitles" are long, e.g. > 10 > words, although I'm not sure if this is the cause. Again I don't > tokenized > this when storing in the index. Any suggestions on how to sort this field > (which is just a String field) w/o running into this RuntimeException? > Thanks in advance! > > -los > -- > View this message in context: > http://www.nabble.com/sorting-issue-with-un-tokenized-field-tf3029674.html#a8418521 > Sent from the Lucene - Java Users mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org > For additional commands, e-mail: java-user-help@lucene.apache.org > > ------=_Part_132293_643903.1169068184478--