Uhhhmmmm, this is really dangerous. If you’ve indexed documents since upgrading, some were indexed with multiValued=false. Now you’ve changed the definition at a fundamental Lucene level and Things Can Go Wrong.
You’re OK if (and only if) you have indexed _no_ documents since you upgraded. But even in that case, there may be other fields with different multiValued values. And if you sort, group, or facet on them when some have been indexed one way and some others, you’ll get errors. I strongly urge you to re-index all your data into a new collection and, perhaps, use collection aliasing to seamlessly switch. Best, Erick > On Sep 25, 2020, at 8:50 AM, Anuj Bhargava <anujb...@gmail.com> wrote: > > It worked. I just added multiValued="true". > > <field name="country" type="text_general" indexed="true" stored="true" > multiValued="true"/> > <field name="doc_c" type="date_range" indexed="true" stored="true"/> > <field name="currency" type="text_general" indexed="true" stored="true" > multiValued="true"/> > <field name="est_cost" type="plong" indexed="true" stored="true"/> > > Thanks for all your help. > > Regards, > > Anuj > > On Fri, 25 Sep 2020 at 18:08, Alexandre Rafalovitch <arafa...@gmail.com> > wrote: > >> Ok, something is definitely not right. In those cases, I suggest >> checking backwards from hard reality. Just in case the file you are >> looking at is NOT the one that is actually used when collection is >> actually setup. Happened to me more times than I can count. >> >> Point your Admin UI to the collection you are having issues and check >> the schema definitions there (either in Files or even in Schema >> screen). I still think your multiValued definition changed somewhere. >> >> Regards, >> Alex. >> >> On Fri, 25 Sep 2020 at 03:57, Anuj Bhargava <anujb...@gmail.com> wrote: >>> >>> Schema on both are the same >>> >>> <field name="country" type="text_general" indexed="true" >> stored="true"/> >>> <field name="doc_c" type="date_range" indexed="true" stored="true"/> >>> <field name="currency" type="text_general" indexed="true" >> stored="true"/> >>> <field name="est_cost" type="plong" indexed="true" stored="true"/> >>> >>> Regards, >>> >>> Anuj >>> >>> On Thu, 24 Sep 2020 at 18:58, Alexandre Rafalovitch <arafa...@gmail.com> >>> wrote: >>> >>>> These are field definitions for _text_ and text, your original >>>> question was about the fields named "country"/"currency" and whatever >>>> type they mapped to. >>>> >>>> Your text/_text_ field is not actually returned to the browser, >>>> because it is "stored=false", so it is most likely a catch-all >>>> copyField destination. You may be searching against it, but you are >>>> returning other (original) fields. >>>> >>>> Regards, >>>> Alex. >>>> >>>> On Thu, 24 Sep 2020 at 09:23, Anuj Bhargava <anujb...@gmail.com> >> wrote: >>>>> >>>>> In both it is the same >>>>> >>>>> In Solr 8.0.0 >>>>> <field name="_text_" type="text_general" multiValued="true" >>>> indexed="true" >>>>> stored="false"/> >>>>> >>>>> In Solr 8.6.2 >>>>> <field name="text" type="text_general" indexed="true" stored="false" >>>>> multiValued="true"/> >>>>> >>>>> On Thu, 24 Sep 2020 at 18:33, Alexandre Rafalovitch < >> arafa...@gmail.com> >>>>> wrote: >>>>> >>>>>> I think that means your field went from multiValued to >> singleValued. >>>>>> Double check your schema. Remember that multiValued flag can be set >>>>>> both on the field itself and on its fieldType. >>>>>> >>>>>> Regards, >>>>>> Alex >>>>>> P.s. However if your field is supposed to be single-valued, maybe >> you >>>>>> should treat it as a feature not a bug. Multivalued fields have >> some >>>>>> restrictions that single-valued fields do not have (around sorting >> for >>>>>> example). >>>>>> >>>>>> On Thu, 24 Sep 2020 at 03:09, Anuj Bhargava <anujb...@gmail.com> >>>> wrote: >>>>>>> >>>>>>> In solr 8.0.0 when running the query the data >> (type="text_general") >>>> was >>>>>>> shown in brackets *[ ]* >>>>>>> "country":*[*"IN"*]*, >>>>>>> "currency":*[*"INR"*]*, >>>>>>> "date_c":"2020-08-23T18:30:00Z", >>>>>>> "est_cost":0, >>>>>>> >>>>>>> However, in solr 8.6.2 the query the data (type="text_general") >> is >>>> not >>>>>>> showing in brackets [ ] >>>>>>> "country":"IN", >>>>>>> "currency":"INR", >>>>>>> "date_c":"2020-08-23T18:30:00Z", >>>>>>> "est_cost":0, >>>>>>> >>>>>>> >>>>>>> How to get the query results to show brackets in Solr 8.6.2 >>>>>> >>>> >>