Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 75802 invoked from network); 30 Jul 2009 20:38:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 30 Jul 2009 20:38:44 -0000 Received: (qmail 6167 invoked by uid 500); 30 Jul 2009 20:38:43 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 6132 invoked by uid 500); 30 Jul 2009 20:38:43 -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 6122 invoked by uid 99); 30 Jul 2009 20:38:43 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jul 2009 20:38:43 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of erickerickson@gmail.com designates 209.85.211.177 as permitted sender) Received: from [209.85.211.177] (HELO mail-yw0-f177.google.com) (209.85.211.177) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jul 2009 20:38:31 +0000 Received: by ywh7 with SMTP id 7so1053658ywh.21 for ; Thu, 30 Jul 2009 13:38:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=QVokKx5L+hJ9R2nqA9mXfDMZdOCkXYZo2UnxuX/37s0=; b=S3tEe1BN28Ua6SBZHCdv9/PDaxjgK3ipBBHs06YzJHu5p7+Piw0U/+9oKPOjgM+S9F pgmzQVYW8Gd7WnDObDXN2uV0RuaQYNxgGDDQOotejI48ICMBBYGVH8nj7QOI4Qop2F5j jWPGdEfetJMs/VKJ2Bu+kHnC3pVy4E4y0teQQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=RqhES25Qo6GalceNZQnAs5LxEdFPhS+Mcu1V3fD+trLp8mMsSYSV9TcYDSJDH4mUED +4cRnP59ejJaXSFKHzQm/6BFcfSOvf9HRD0OX6d56evcASl0ESvLiul+Ya4E/3WBcga4 /sjydlAqpDrTIdwRideGLfW09efwNQtQjEnjg= MIME-Version: 1.0 Received: by 10.231.33.4 with SMTP id f4mr458457ibd.8.1248986289248; Thu, 30 Jul 2009 13:38:09 -0700 (PDT) In-Reply-To: <24718799.post@talk.nabble.com> References: <24716042.post@talk.nabble.com> <447441.40636.qm@web52910.mail.re2.yahoo.com> <24718799.post@talk.nabble.com> Date: Thu, 30 Jul 2009 16:38:09 -0400 Message-ID: <359a92830907301338k24b767f7v8a6251b9d3cef9b0@mail.gmail.com> Subject: =?ISO-8859-1?Q?Re=3A_=24_or_=A3_symbols_are_excluded_from_Search_Query?= From: Erick Erickson To: java-user@lucene.apache.org Content-Type: multipart/alternative; boundary=0022152d6ec1199c6c046ff248e2 X-Virus-Checked: Checked by ClamAV on apache.org --0022152d6ec1199c6c046ff248e2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable WhitespaceAnalyzer won't fold case. It won't strip any "odd" characters out= . It won't, in fact, do anything except break on white space. You might want to write your own analyzer that incorporates, some of the filters, especially LowercaseFilter. On Wed, Jul 29, 2009 at 9:04 AM, cbowditch wrot= e: > > > > Ahmet Arslan wrote: > > > > > >> Can anyone tell me how I can search my index for $ or =A3. > > > > $ or =A3 or euro character are not reserved characters that are specifi= ed > in > > QueryParser. I just verified it using the code below: (in Lucene 2.4.1) > > > > org.apache.lucene.queryParser.QueryParser qp =3D new > > org.apache.lucene.queryParser.QueryParser("title", new > > WhitespaceAnalyzer()); > > Query q =3D qp.parse("$ahmet$ AND =A3arslan=A3 te$s=A3t"); > > System.out.println(q.toString()); > > > > Where the output is : +title:$ahmet$ +title:=A3arslan=A3 title:te$s=A3t > > > > Probably your analyzer is eating up those characters. Are you using > > StandardAnalyzer or SimpleAnalyzer? LetterTokenizer and StandardTokeniz= er > > breaks/splits words at those characters. If thats the cause of the > > problem, use something like WhitespaceAnalyzer or construct your querie= s > > programmatically using Lucene Query API. e.g. TermQuery etc. > > > > Thanks for the suggestions. I had tried SimpleAnalyzer and StandardAnalyz= er > within Luke. When I switched to WhitespaceAnalyzer the $ and =A3 symbols = were > maintained. > > Within my own Application we seem to be using a custom Analyzer that sub > classes Analyzer. What is the implication of switch the base class to > WhitespaceAnalyzer? > > Thanks, > > Chris > -- > View this message in context: > http://www.nabble.com/%24-or-%C2%A3-symbols-are-excluded-from-Search-Quer= y-tp24716042p24718799.html > 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 > > --0022152d6ec1199c6c046ff248e2--