# Mapper\_parsing\_exception for an income field range

**URL:** https://discuss.elastic.co/t/mapper-parsing-exception-for-an-income-field-range/169223
**Category:** Elasticsearch
**Created:** [February 20, 2019, 1:26pm UTC](https://discuss.elastic.co/t/mapper-parsing-exception-for-an-income-field-range/169223 "2019-02-20T13:26:54Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![parshvms](https://avatars.discourse-cdn.com/v4/letter/p/bb73d2/32.png) [@parshvms](https://discuss.elastic.co/u/parshvms)
#### Post date: [February 20, 2019, 1:26pm UTC](https://discuss.elastic.co/t/mapper-parsing-exception-for-an-income-field-range/169223/1 "2019-02-20T13:26:54Z")

</div>

Hello,

I have a field named "Income Bracket" that has values like  
"$50,000 - $100,000",  
"$50,000 and under",  
"$100,000 - $500,000" etc.

I am trying to load the doc with this field and couple of others using logstash however unable to load due to the following error:

[2019-02-19T16:26:56,979][WARN][logstash.outputs.elasticsearch] Could not index event to Elasticsearch. {:status=\>400, :action=\>["index", {:\_id=\>nil, :\_index=\>"verbatims\_index", :\_type=\>"verbatim", :routing=\>nil}, #LogStash::Event:0x1538332c], :response=\>{"index"=\>{"\_index"=\>"verbatims\_index", "\_type"=\>"verbatim", "\_id"=\>"JCanB2kBoGbYmP3flOO5", "status"=\>400, "error"=\>{"type"=\>"mapper\_parsing\_exception", "reason"=\>"failed to parse field [Income Bracket] of type [integer\_range]", "caused\_by"=\>{"type"=\>"mapper\_parsing\_exception", "reason"=\>"error parsing field [Income Bracket], expected an object but got Income Bracket"}}}}}

Could anyone please help me out to resolve?

Config file looks like below:  
\</\>  
filter {  
mutate {  
convert =\> { "Income Bracket" =\> "string" }  
gsub =\> ["Income Bracket","$",""]  
}  
}

Also the json template I am using is as below:

"Income Bracket": {  
"type": "string",  
"index" : "not\_analyzed"  
},

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [March 20, 2019, 1:26pm UTC](https://discuss.elastic.co/t/mapper-parsing-exception-for-an-income-field-range/169223/2 "2019-03-20T13:26:59Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
