Both these links are related to the same problem I believe:

http://www.nabble.com/query-parsing-error-to14124285.html#a14140108
and
https://issues.apache.org/jira/browse/SOLR-435

On Tue, Apr 1, 2008 at 1:28 PM, Lars Kotthoff (JIRA) <[EMAIL PROTECTED]>
wrote:

>
>     [
> https://issues.apache.org/jira/browse/SOLR-525?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel]
>
> Lars Kotthoff updated SOLR-525:
> -------------------------------
>
>    Attachment: solr-search-empty-query.patch
>
> Patch to fix the NullPointerException. Instead of setting the query string
> of the ResponseBuilder object to whatever the SolrParams object returns,
> check whether the returned value is null, and if so, set the query string to
> "". This will raise a ParserException when no or an empty search string is
> passed to Solr.
>
> I'm not sure whether this is the optimal solution, so if anyone has a
> better idea of how to handle this, please comment. This solution only
> provides a more meaningful error message than a NullPointerException.
>
> > NullPointerException with no query or empty query
> > -------------------------------------------------
> >
> >                 Key: SOLR-525
> >                 URL: https://issues.apache.org/jira/browse/SOLR-525
> >             Project: Solr
> >          Issue Type: Bug
> >          Components: search
> >    Affects Versions: 1.3
> >         Environment: Tomcat 5.5
> >            Reporter: Lars Kotthoff
> >            Priority: Minor
> >         Attachments: solr-search-empty-query.patch
> >
> >
> > When calling the search URL with no query or an empty query (i.e.
> http://localhost:8080/solr/select/ or
> http://localhost:8080/solr/select/?q=), Solr throws a
> NullPointerException. The value for the query string returned by the
> SolrParams object is null, but QueryComponent tries to process it.
> > I encountered this bug because of a bug in my application calling the
> search URL, but arguably the response should be more constructive.
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>


-- 
Regards,
Shalin Shekhar Mangar.

Reply via email to