Consider using the edismax query parser, which allows you to specify q.alt which is an alternative query such as "*:". Or use an application layer to handle the situation before it gets to Solr.

-- Jack Krupansky

-----Original Message----- From: vit
Sent: Friday, May 30, 2014 9:01 AM
To: solr-user@lucene.apache.org
Subject: How to check and handle empty Solr query

In my code sometimes I get an emty query. Namely ... q=&.... which causes
"bad request" exception.
How to gracefully check query correctness and bypass execution if it is not
correct.



--
View this message in context: http://lucene.472066.n3.nabble.com/How-to-check-and-handle-empty-Solr-query-tp4138877.html Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to