SimplePostTool: WARNING: Response: {
"responseHeader":{
"status":400,
"QTime":176},
"error":{
"metadata":[
"error-class","org.apache.solr.common.SolrException",
"root-error-class","java.lang.NumberFormatException"],
"msg":"ERROR: [doc=fc396e71-4b97-4ae5-bf31-2ccd0953d6d3] Error adding field 'seasonNumber'='\\N' msg=For input string: \"\\N\"",
"code":400}}
The file to be indexed is a .tsv file and 2 columns (seasonNumber and episodeNumber) have integer values but also Null values denoted by \N
I tried to add following lines to managed-schema.xml
but to no avail :
<fieldType name="seasonNumber" class="solr.TextField" multiValued="true"/>
<fieldType name="episodeNumber" class="solr.TextField" multiValued="true"/>
My post command is:
./post -c imdb -host *hostname* -params "separator=%09" -type text/csv ~/imdb-dataset/title.episode.tsv
Can someone please help in this?
I solved it by adding:
<field name="seasonNumber" type="text_general" uninvertible="true" indexed="true" stored="true"/>
<field name="episodeNumber" type="text_general" uninvertible="true" indexed="true" stored="true"/>
to managed-schema.xml
Basically the type should be: text_general.