lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alessandro Hoss <aleh...@gmail.com>
Subject Re: Synonym not working in 4.10 / CDH 5.14
Date Thu, 01 Mar 2018 18:27:13 GMT
How's your synonyms declared in the file?

That xml comment (<!-- -->) in the synonym filter section isn't there in
your running solr schema.xml, right? :)

On Thu, Mar 1, 2018 at 2:53 PM Abhi Basu <9000revs@gmail.com> wrote:

> Yes have tested with PA and NY, nothing works.
>
> On Thu, Mar 1, 2018 at 11:38 AM, Alessandro Hoss <alehoss@gmail.com>
> wrote:
>
> > Have you tested with another state?
> >
> > I'm asking because maybe solr is considering "OR" as a clause separator
> > instead of a search term, and in this case the problem is not with
> synonym,
> > it is with your query.
> >
> > On Thu, Mar 1, 2018 at 2:24 PM Abhi Basu <9000revs@gmail.com> wrote:
> >
> > >  Can someone please help me?
> > >
> > > Schema.xml
> > >
> > > <field name="PropertyAddressState" type="string" indexed="true"
> > > stored="true" docValues="true"/>
> > >
> > > <field name="text" type="text_general" indexed="true" stored="false"
> > > multiValued="true"/>
> > >
> > >
> > > <copyfield source="PropertyAddressState" dest="text"/>
> > >
> > >
> > > <fieldType name="text_general" class="solr.TextField"
> > > positionIncrementGap="100">
> > >   <analyzer type="index">
> > >     <tokenizer class="solr.StandardTokenizerFactory"/>
> > >     <filter class="solr.StopFilterFactory" ignoreCase="true"
> > > words="stopwords.txt" />
> > >     <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt"
> > > ignoreCase="true" expand="true"
> > > tokenizerFactory="solr.StandardTokenizerFactory"/>
> > >     <filter class="solr.LowerCaseFilterFactory"/>
> > >   </analyzer>
> > >   <analyzer type="query">
> > >     <tokenizer class="solr.StandardTokenizerFactory"/>
> > >     <filter class="solr.StopFilterFactory" ignoreCase="true"
> > > words="stopwords.txt" />
> > >     <!--filter class="solr.SynonymFilterFactory"
> > > synonyms="synonyms.txt" ignoreCase="true" expand="true"/-->
> > >     <filter class="solr.LowerCaseFilterFactory"/>
> > >   </analyzer>
> > > </fieldType>
> > >
> > >
> > >
> > >
> > > Synonyms.txt has been populated with State abbreviations and names.
> > >
> > >
> > > When searching for
> > >
> > > PropertyAddressState:"Oregon", I do not find docs with "OR".
> > >
> > >
> > >
> > > What am I missing?
> > >
> > >
> > > Thanks,
> > >
> > > Abhi
> > >
> >
>
>
>
> --
> Abhi Basu
>

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