Return-Path: Delivered-To: apmail-jakarta-lucene-user-archive@www.apache.org Received: (qmail 17069 invoked from network); 5 Oct 2004 15:19:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 5 Oct 2004 15:19:29 -0000 Received: (qmail 94360 invoked by uid 500); 5 Oct 2004 15:18:56 -0000 Delivered-To: apmail-jakarta-lucene-user-archive@jakarta.apache.org Received: (qmail 94225 invoked by uid 500); 5 Oct 2004 15:18:55 -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 94147 invoked by uid 99); 5 Oct 2004 15:18:54 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from [205.158.62.197] (HELO ws6-2.us4.outblaze.com) (205.158.62.197) by apache.org (qpsmtpd/0.28) with SMTP; Tue, 05 Oct 2004 08:18:53 -0700 Received: (qmail 20788 invoked from network); 5 Oct 2004 15:18:31 -0000 Received: from unknown (HELO ?128.143.167.108?) (erik@hatcher.net@128.143.167.108) by ws6-2.us4.outblaze.com with SMTP; 5 Oct 2004 15:18:31 -0000 Mime-Version: 1.0 (Apple Message framework v619) In-Reply-To: References: Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Erik Hatcher Subject: Re: BooleanQuery - Too Many Clases on date range. Date: Tue, 5 Oct 2004 11:18:50 -0400 To: "Lucene Users List" X-Mailer: Apple Mail (2.619) X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Oct 4, 2004, at 2:12 PM, Chris Fraschetti wrote: > absoultely, limiting the user's query is no problem here. I've > currently implemented the lucene javascript to catcha lot of user > quries that could cause issues.. blank queries, ? or * at the > beginning of query, etc etc... but I couldn't think of a way to > prevent the user from doing a* but not comment* wanting comments > or commentary... any suggestions would be warmly welcomed. > I recommend subclassing QueryParser, and overriding getPrefixQuery and getWildcardQuery. In both of the overridden methods, throw a ParseException. You should be handling ParseException gracefully somehow already, so that should do the trick. Erik --------------------------------------------------------------------- To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: lucene-user-help@jakarta.apache.org