-
Notifications
You must be signed in to change notification settings - Fork 25.8k
MapperParsingException[Wrong value for index [yes] for field [...]] #2088
Copy link
Copy link
Closed
Description
I get the following error MapperParsingException[Wrong value for index [yes] for field [date]], when I try to put the following mapping into my totally new and empty index (created with curl -XPUT http://localhost:9200/myindex/).
curl -XPUT http://localhost:9200/myindex/mytype/_mapping -d ' {
"mytype": {
"properties": {
"date": {
"type": "long",
"store": "yes",
"index": "yes",
"omit_norm": "yes",
"omit_term_freq_and_positions": "yes"
}
}
}
}'
Setting index to no works.
In Java using Lucene 3.6.0 I can do the following:
NumericField f = new NumericField("date", Field.Store.Yes, true);
f.setOmitNorms(true);
f.setOmitTermFreqAndPositions(true);
f.setLongValue(1L);
Document d = new Document();
d.add(f);From this (and the documentation here, which doesn't mention that it's illegal what I'm trying to do) I assume what I'm trying to do is doable.
(I realize that elasticsearch has a date type, but I must use the mapping mentioned above.)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Fields
Give feedbackNo fields configured for issues without a type.