Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7753295
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T12:01:27+00:00 2026-06-01T12:01:27+00:00

i receive the following error when trying to implement auto-complete based on edismax type.

  • 0

i receive the following error when trying to implement auto-complete based on edismax type.

SEVERE: java.lang.IllegalStateException: field "locality_ng" was indexed without position data; cannot run PhraseQuery (term=львів)
at org.apache.lucene.search.PhraseQuery$PhraseWeight.scorer(PhraseQuery.java:241)
at org.apache.lucene.search.DisjunctionMaxQuery$DisjunctionMaxWeight.scorer(DisjunctionMaxQuery.java:145)
at org.apache.lucene.search.BooleanQuery$BooleanWeight.scorer(BooleanQuery.java:317)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:551)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:324)
at org.apache.solr.search.SolrIndexSearcher.getDocListNC(SolrIndexSearcher.java:1275)

schema types:

        <fieldType name="text_suggest" class="solr.TextField" positionIncrementGap="100">
        <analyzer type="index">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.StandardTokenizerFactory"/>
            <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="1" splitOnCaseChange="1" splitOnNumerics="1" preserveOriginal="1" />
            <filter class="solr.LowerCaseFilterFactory"/>
        </analyzer>
        <analyzer type="query">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.StandardTokenizerFactory"/>
            <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="0" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="0" splitOnNumerics="0"/>
            <filter class="solr.LowerCaseFilterFactory"/>
        </analyzer>
    </fieldType>

    <!-- autocomplete_edge : Will match from the left of the field, e.g. if the document field
         is "A brown fox" and the query is "A bro", it will match, but not "brown"
    -->
    <fieldType name="autocomplete_edge" class="solr.TextField">
        <analyzer type="index">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.KeywordTokenizerFactory"/>
            <filter class="solr.LowerCaseFilterFactory"/>
            <filter class="solr.PatternReplaceFilterFactory" pattern="([\.,;:_])" replacement=" " replace="all"/>
            <filter class="solr.EdgeNGramFilterFactory" maxGramSize="50" minGramSize="2"/>
        </analyzer>
        <analyzer type="query">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.KeywordTokenizerFactory"/>
            <filter class="solr.LowerCaseFilterFactory"/>
            <filter class="solr.PatternReplaceFilterFactory" pattern="([\.,;:_])" replacement=" " replace="all"/>
            <filter class="solr.PatternReplaceFilterFactory" pattern="^(.{50})(.*)?" replacement="$1" replace="all"/>
        </analyzer>
    </fieldType>

    <!-- autocomplete_ngram : Matches any word in the input field, with implicit right truncation.
         This means that the field "A brown fox" will be matched by query "bro".
         We use this to get partial matches, but these whould be boosted lower than exact and left-anchored
    -->
    <fieldType name="autocomplete_ngram" class="solr.TextField">
        <analyzer type="index">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.StandardTokenizerFactory"/>
            <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>
            <filter class="solr.LowerCaseFilterFactory"/>
            <filter class="solr.EdgeNGramFilterFactory" maxGramSize="20" minGramSize="2"/>
        </analyzer>
        <analyzer type="query">
            <!--charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/-->
            <tokenizer class="solr.StandardTokenizerFactory"/>
            <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="0" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="0"/>
            <filter class="solr.LowerCaseFilterFactory"/>
            <filter class="solr.PatternReplaceFilterFactory" pattern="^(.{20})(.*)?" replacement="$1" replace="all"/>
        </analyzer>
    </fieldType>

schema fields

        <!-- AutoComplete fields
         Construct documents containing these fields for all suggestions you like to provide
         Then use a dismax query to search on some fields, display some fields and boost others
     -->
    <field name="locality_id" type="int" indexed="true" stored="true" required="true"/>
    <!-- The main text to return as the suggestion. This is not searched -->
    <field name="locality_suggest" type="text_suggest" indexed="true" stored="true" omitNorms="true" multiValued="true" />

    <!-- A variant of textsuggest which only matches from the very left edge -->
    <copyField source="locality_suggest" dest="locality_nge"/>
    <field name="locality_nge" type="autocomplete_edge" indexed="true" stored="false" multiValued="true" />

    <!-- A variant of textsuggest which matches from the left edge of all terms (implicit truncation) -->
    <copyField source="locality_suggest" dest="locality_ng"/>
    <field name="locality_ng" type="autocomplete_ngram" indexed="true" stored="false" omitNorms="true" omitTermFreqAndPositions="true" multiValued="true" />

solr config, use the following request handler with edismax type:

  <requestHandler class="solr.SearchHandler" name="autocomplete" >
<lst name="defaults">
    <str name="defType">edismax</str>
    <str name="rows">10</str>
    <str name="fl">*,score</str>
    <str name="qf">locality_suggest locality_ng^5.0 locality_nge^10.0</str>
    <str name="debugQuery">false</str>
</lst>

this error occurred only if query contains specific symbols like + – $ @ after word

львів+в
київ+а

any suggestions would be great

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T12:01:28+00:00Added an answer on June 1, 2026 at 12:01 pm

    Change

        <field name="locality_ng" type="autocomplete_ngram" indexed="true" stored="false" omitNorms="true" omitTermFreqAndPositions="true" multiValued="true" />
    

    into

        <field name="locality_ng" type="autocomplete_ngram" indexed="true" stored="false" omitNorms="true" multiValued="true" />
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I receive the following error when trying to run my ASP.NET MVC application: The
I am received the following error while trying to implement a C# extension function
While trying to make a map in Scala, I receive the following error message:
I am trying to initialize NSDictionary but it gives me following error: Program received
I receive the following error when running a new compass project in OSX 10.7.3.
In my application I receive the following error: The context cannot be used while
Using HttpClient , I receive the following error when attempting to communicate over HTTPS:
When attempting to do an EntitySave(publications,arguments); .. I receive the following error. ids for
whenever I compile my code, I receive the following errors: error: constructor Player in
I receive the error below when running the following function. The catch says the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.