Thank you very much. The reason is what you said, we need to rebuild the index
to recover(~very sad~)
The scenarios where the problem occurs are as follows:
1. (7.7) the managed-schema of my configset contains _root_ field
2. (7.7) create collection with my configset
3. (7.7) write doc
id=1, name=alice, age=10
4. upgrade from 7.7 to 8.11
5. (8.11) write doc
id=1, name=alice2, age=11
6. (8.11) NumFound=2 when querying with debugQuery=true&q=id:1
At 2022-06-12 00:29:09, "戴晓彬" <[email protected]> wrote:
>There is no _root_ field in the index data before the upgrade. The 8.x version
>will judge whether it is the same record according to _root_, so the update
>will become two after the upgrade.
>It is recommended to reindex after the upgrade.
>
>> 2022年6月12日 00:10,YangLiu <[email protected]> 写道:
>>
>>
>>
>>
>> Thank you for your reply.
>> The _root_ field is defined as follows:
>>
>>
>>
>>
>> <fieldname="_root_"type="StrField"docValues="false"indexed="true"stored="false"/>
>> <fieldTypename="StrField"class="solr.StrField"sortMissingLast="true"docValues="true"/>
>>
>>
>>
>>
>>
>> At 2022-06-12 00:05:00, "戴晓彬" <[email protected]> wrote:
>>> check the managed-schema to see if the _root_ field is defined.
>>>
>>>> 2022年6月11日 23:58,slly <[email protected]> 写道:
>>>>
>>>> Hello everyone.
>>>> We recently upgraded the online version from Solr 7 to 8.11, we found a
>>>> very strange problem.
>>>>
>>>>
>>>> Before upgrade, we wrote a row of data, the id is uniqueKey.
>>>> id=1, name=alice, age=10
>>>> After upgrade, we write three rows of data and id=2 is repeated.
>>>> id=1, name=alice2, age=11
>>>> id=2, name=nick, age=30
>>>> id=2, name=nick2, age=31
>>>>
>>>>
>>>> We found NumFound=2 when querying with debugQuery=true&q=id:1, and
>>>> NumFound=1 when querying with debugQuery=true&q=id:3
>>>>
>>>>
>>>> For historical data, the default 'overwrite' is false?
>>>>
>>>>
>>>>
>>>>
>>>> Thanks.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>