String fields are unanalyzed so this simply will not work. String
fields are case sensitive, don't split on whitespace or non-letters
etc.

You might get significant mileage out of the admin/analysis page to
see exactly what tokenizations occur. Your original question implied
you were looking for complete names. For partial fields you need
analyzed terms.

Try the multiValued approach with positionIncrementGap then. And also
consider complexPhraseQueryParser, it handles things like "jam* cook"
where the usual parsers don't.
https://cwiki.apache.org/confluence/display/solr/Other+Parsers#OtherParsers-ComplexPhraseQueryParser

Best,
Erick

On Wed, Apr 13, 2016 at 4:54 PM, Thrinadh  Kuppili
<thrinadh...@gmail.com> wrote:
> Thanks Eric,
>
> It tried by indexing with one multivalued field as name but I am not getting
> the expected result, below are the stored data and query to fetch from solr
>
> Name: James_Cook
>
> fq = name:Jam*
>
> I should be able to search using first name (james) or Last name ( cook) or
> partial names (jam or coo)
> so I appended * before searching .
>
> The field Name is defined as sol.strfield with no filters/tokenizer's.
>
> Thnx
> Thrinadh
>
>
>
>
>
>
>
>
> --
> View this message in context: 
> http://lucene.472066.n3.nabble.com/How-to-search-for-a-First-Last-of-contact-which-are-stored-in-differnet-multivalued-fields-tp4269901p4270011.html
> Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to