lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <>
Subject Re: Alphanumeric wildcard search problem
Date Fri, 03 Sep 2010 00:46:00 GMT
All I can say is that I just tried it with the following definitions
and it works as expected. That is:

nothing (casing issue) and


3 documents

<fieldType name="textShoaib" class="solr.TextField"
<analyzer type="index">
 <tokenizer class="solr.StandardTokenizerFactory"/> just playing
 <filter class="solr.StopFilterFactory"
<filter class="solr.LowerCaseFilterFactory"/>
 <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
 <analyzer type="query">
 <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt"
ignoreCase="true" expand="true"/>
 <filter class="solr.StopFilterFactory" ignoreCase="true"
<filter class="solr.LowerCaseFilterFactory"/>
 <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>

<field name="eoe" type="textShoaib" indexed="true" />

where the relevant documents had the following:

<field name="eoe">R-1 and some stuff</field>
<field name="eoe">r-1 really now</field>
<field name="eoe">R-1</field>

searching for r* and r-* also returned three documents.
Note that using StandardAnalyzer and WhitespaceAnalyzer
didn't make any difference.

browsing the schema from the admin page shows the tokena

Are you totally and absolutely sure that you're using the schema you think
you are?
And you restarted SOLR after you made schema changes?
And you re-indexed your data?

I also tried it with the dismax query, and it works there too:

returns 3 results, where standard2 is defined like this:

<requestHandler name="standard2" class="solr.SearchHandler">
<!-- default values for query parameters -->
<lst name="defaults">
<str name="defType">dismax</str>
<str name="echoParams">explicit</str>
<str name="tie">0.6</str>
<str name="qf">eoe^2.3 mat_nr^0.4</str>
<str name="mm">0%</str>
      <int name="rows">10</int>
      <str name="fl">*</str>
      <str name="version">2.1</str>

So in sum, I suspect that you've made some innocous-seeming
change somewhere that you've forgotten about (easy to do when
you're trying a zillion things and frustrated). So, here's what I'd

back up and forget dismax for a while, just get it all working
with the normal query parser and gradually add things back
in until you either fail succeed all the way back to dismax.

BTW, you probably want to specify dismax with the qf parameter,
pf stands for "phrase fields" where qf stands for "query fields".
pf worked for me, but I doubt that's what you're really after.

This is all on SOLR 1.4.1 BTW.


On Thu, Sep 2, 2010 at 6:12 AM, Hasnain <> wrote:

> Erick,
>       I have checked with lowercasing, and yes there are Items by this
> name.
> Im not getting anywhere with this, tried many things and Im really
> perplexed.
> any other suggestion?
> Oh dear. Wildcard queries aren't analyzed, so I suspect it's a casing
> issue.
> Try two things:
> 1> search for r-1*
> 2> look in your index and be sure the actual terms are there as you expect.
> Erick
> --
> View this message in context:
> Sent from the Solr - User mailing list archive at

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message