Return-Path: Delivered-To: apmail-jakarta-lucene-user-archive@www.apache.org Received: (qmail 18123 invoked from network); 21 May 2004 15:36:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 21 May 2004 15:36:50 -0000 Received: (qmail 66210 invoked by uid 500); 21 May 2004 15:36:47 -0000 Delivered-To: apmail-jakarta-lucene-user-archive@jakarta.apache.org Received: (qmail 66060 invoked by uid 500); 21 May 2004 15:36:46 -0000 Mailing-List: contact lucene-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Users List" Reply-To: "Lucene Users List" Delivered-To: mailing list lucene-user@jakarta.apache.org Received: (qmail 65911 invoked by uid 98); 21 May 2004 15:36:45 -0000 Received: from alex.bourne@hsbcam.com by hermes.apache.org by uid 82 with qmail-scanner-1.20 (clamuko: 0.70. Clear:RC:0(193.108.75.30):. Processed in 0.089799 secs); 21 May 2004 15:36:45 -0000 X-Qmail-Scanner-Mail-From: alex.bourne@hsbcam.com via hermes.apache.org X-Qmail-Scanner: 1.20 (Clear:RC:0(193.108.75.30):. Processed in 0.089799 secs) Received: from unknown (HELO NNT243.systems.uk.hsbc) (193.108.75.30) by hermes.apache.org with SMTP; 21 May 2004 15:36:44 -0000 Received: from emea-smtp-05.systems.uk.hsbc (unverified) by NNT243.systems.uk.hsbc (Content Technologies SMTPRS 4.3.6) with ESMTP id for ; Fri, 21 May 2004 16:39:52 +0100 Sensitivity: Subject: Query parser and minus signs To: lucene-user@jakarta.apache.org From: alex.bourne@hsbcam.com Date: Fri, 21 May 2004 16:36:24 +0100 Message-ID: X-MIMETrack: Serialize by Router on EMEA-SMTP-05/SERVERS/HSBC (Release 6.0.1CF3|July 29, 2003) at 21/05/2004 16:36:26 MIME-Version: 1.0 Content-type: text/plain; charset="us-ascii" X-Spam-Rating: hermes.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Hi All, I'm using Lucene on a site that has split content with a branch containing pages in English and a separate branch in Chinese. Some of the chinese pages include some (untranslatable) English words, so when a search is carried out in either language you can get pages from the wrong branch. To combat this we introduced a language field into the index which contains the standard language codes: en-UK and zh-HK. When you parse a query e.g. language:"en\-UK" you could reasonably expect the search to recover all pages with the language field set to "en-UK" (the minus symbol should be escaped by the backslash according to the FAQ). Unfortunately the parser seems to return "en UK" as the parsed query and hence returns no documents. Has anyone else had this problem, or could suggest a workaround ?? as I have yet to find a solution in the mailing archives or elsewhere. Many thanks in advance, Alex Bourne _____________________________________________________ This transmission has been issued by a member of the HSBC Group ("HSBC") for the information of the addressee only and should not be reproduced and / or distributed to any other person. Each page attached hereto must be read in conjunction with any disclaimer which forms part of it. This transmission is neither an offer nor the solicitation of an offer to sell or purchase any investment. Its contents are based on information obtained from sources believed to be reliable but HSBC makes no representation and accepts no responsibility or liability as to its completeness or accuracy. --------------------------------------------------------------------- To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: lucene-user-help@jakarta.apache.org