Hi,
 The first requirement works fine for me, but i was unaware of the Phrase
Queries for the second one.

 I found this link very much useful regarding the same.
http://wiki.apache.org/solr/SolrRelevancyCookbook

  Thanks for the help guys,

Regards
Dilip

-----Original Message-----
From: Erik Hatcher [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 18, 2007 6:29 PM
To: solr-user@lucene.apache.org
Subject: Re: Search for Java Programming vs "Java Programming"


On Sep 18, 2007, at 7:14 AM, Dilip.TS wrote:

>
> Hi,
>
>  I have the following requirement:
>  When the user searches for the keyword say Java Programming ,  the
> user
> should be shown the results satisfying the condition Java AND
> Programming.
>  But when he types "Java Programming" (i.e within double quotes),
> the user
> should be shown with the results exactly matching Java Programming
> as a
> single word (similar to doing a search on google).
>  The user should be shown with the proper results accordingly.
>  Any help would be highly appreciated.

Dilip - are you seeing results indicating a problem with this in your
application?   Query syntax is spelled out in more detail here:

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

The one difference you may have is  <solrQueryParser
defaultOperator="OR"/> in schema.xml.  Change that to "AND" to
satisfy your first requirement.

        Erik

Reply via email to