Return-Path: Delivered-To: apmail-lucene-general-archive@www.apache.org Received: (qmail 7326 invoked from network); 30 May 2008 23:58:52 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 May 2008 23:58:52 -0000 Received: (qmail 59856 invoked by uid 500); 30 May 2008 23:58:54 -0000 Delivered-To: apmail-lucene-general-archive@lucene.apache.org Received: (qmail 59421 invoked by uid 500); 30 May 2008 23:58:53 -0000 Mailing-List: contact general-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: general@lucene.apache.org Delivered-To: mailing list general@lucene.apache.org Received: (qmail 59410 invoked by uid 99); 30 May 2008 23:58:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 May 2008 16:58:53 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [208.69.42.181] (HELO radix.cryptio.net) (208.69.42.181) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 May 2008 23:58:05 +0000 Received: by radix.cryptio.net (Postfix, from userid 1007) id 392AA71C414; Fri, 30 May 2008 16:58:22 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by radix.cryptio.net (Postfix) with ESMTP id 2D2BF71C40C for ; Fri, 30 May 2008 16:58:22 -0700 (PDT) Date: Fri, 30 May 2008 16:58:22 -0700 (PDT) From: Chris Hostetter To: general@lucene.apache.org Subject: Re: Problem after combining queries In-Reply-To: <17466089.post@talk.nabble.com> Message-ID: References: <17466089.post@talk.nabble.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Checked: Checked by ClamAV on apache.org FYI: your questions sems to be about using the Lucene Java API. You should probably post your question to the java-user@lucene mailing list if you have questions about using that API. Posting actaul code (instead of just a description of what your code is suppose to do) can also help people figure out why it's not working as you expect. : Hi all, : I have to implement searching for the following criteria: : : "search all documents with 'status' approved and 'createddate' within the : given range." : where 'status' and 'createddate' are two fields. : : for this i created a field query for 'status' with occurance 'Must' and a : range query for 'createddate'. : Then i combined that two and searched. : : But the search results contains documents which are not approved.[Approved : documents comes first followed by others !!!] : : If i remove the range query, results will contain only approved documents. : : How to solve this? -Hoss