I am converting a SOLR 4.10 db to SOLR 7.1

It is NOT schemaless - so it uses a ClassicIndexSchemaFactory.

In 4.10, I have a field that is a phone number (here's the schema information 
for the field):

<field name="Phone" type="string" indexed="false" stored="true"/>

When inserting documents into SOLR, there are some documents where the value of 
Phone is an empty string or a single blank space.

When running a query against SOLR 4.10, the documents returned that have an 
empty or single space in Phone, include the phone field in the documents:

...
"FirstName":"Bob, No Phone",
"Phone":"",
"State":"WA"
...
"FirstName":"Sandy, No Phone",
"Phone":""
"State":"CA"
...
"FirstName":"Donald, With Phone",
"Phone":"123-123-1234",
"State":"NY"
...

But when these same rows are inserted into SOLR 7.1, the documents returned for 
those rows have no Phone field

...
"FirstName":"Bob, No Phone",
"State":"WA"
...
"FirstName":"Sandy, No Phone",
"State":"CA"
...
"FirstName":"Donald, With Phone",
"Phone":"123-123-1234",
"State":"NY"
...

See how Donald has a phone number because there was a "non-blank" phone number.

I also looked at the version of Java installed on the two boxes - the SOLR 4.10 
box has java 1.8.0_161, and the SOLR 7.1 box has java 1.8.0_40. I wouldnt think 
the java version difference would cause that - I believe SOLR just requires 1.8.

Is this something that has been added since 4.10?

Is there a schema setting or SOLRConfig.xml or Schema.xml setting that can turn 
the 4.10 behavior back on?

Thanks,

Rick Hodder

Reply via email to