On Thu, Sep 9, 2010 at 2:40 PM, Chris Hostetter <[email protected]> wrote: > > : > I don't think so ... that's what q.alt is for. > : > : q.alt is for dismax. > : What's wrong with matching no documents if no query is specified? > : It's actually more consistent when someone tries to specify a > : zero-length query (i.e. q=) > > My bad - i was mistakenly thinking we had promoted q.alt to be a > QueryComponent param. > > where are you suggesting we make the change? to QueryComponent or to the > LuceneQParser? > > It makes sense in principle, but seems like QueryComponent shouldn't make > any assumptions if there is no "q" param - the QParser might have it's own > special rules (like DisMaxQParser and q.alt).
Right, that's why I was thinking the LuceneQParser. > but if we put it in the > QParser, then every QParser that doesn't have special logic needs to deal > with it consistently. > > Off the top of my head: we can make the QParsers return null if they > consider the request "valid" but containing no meaningful query (ie: blank > or missing q param) and then make QueryComponent short circut when the > Query object is null. Hmmm, that may be an even better idea. -Yonik http://lucenerevolution.org Lucene/Solr Conference, Boston Oct 7-8 --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
