Hi Dipti,

just to make sure: are you aware of

http://wiki.apache.org/solr/DisMaxQParserPlugin

This will handle the user input in a very conventional and user friendly
way. You just have to specify on which fields you want it to search.
With the 'mm' parameter you have a powerfull option to specify how much
of a search query has to match (more flexible than defining a default
operator).

Cheers,
Chantal

On Fri, 2012-01-20 at 23:52 +0100, Dipti Srivastava wrote:
> Hi All,
> I ma using HTTP/JSON to search my documents in Solr. Now the client provides 
> the query on which the search is based.
> What is a good way to validate the query string provided by the user.
> 
> On the other hand, if I want the user to build this query using some Solr api 
> instead of preparing a lucene query string which API can I use for this?
> I looked into
> SolrQuery in SolrJ but it does not appear to have a way to specify the more 
> complex queries with the boolean operators and operators such as ~,+,- etc.
> 
> Basically, I am trying to avoid running into bad query strings built by the 
> caller.
> 
> Thanks!
> Dipti
> 
> ________________________________
> This message is private and confidential. If you have received it in error, 
> please notify the sender and remove it from your system.
> 

Reply via email to