# Search with analyzer

**URL:** <https://discuss.elastic.co/t/search-with-analyzer/67507>\
**Category:** Elasticsearch\
**Created:** [November 29, 2016, 3:15pm UTC](https://discuss.elastic.co/t/search-with-analyzer/67507 "2016-11-29T15:15:36Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![prasad\_kp](https://avatars.discourse-cdn.com/v4/letter/p/dc4da7/32.png) [@prasad\_kp](https://discuss.elastic.co/u/prasad_kp)\
**Post date:** [November 29, 2016, 3:15pm UTC](https://discuss.elastic.co/t/search-with-analyzer/67507/1 "2016-11-29T15:15:36Z")

</div>

Here is my index setting and mapping

analysis": {  
"filter": {  
"synonym": {  
"type": "synonym",  
"synonyms\_path": "D:\MyElasticSearch\elasticsearch-1.5.2\config\synonyms.txt",  
"ignore\_case": "true"  
}  
},  
"analyzer": {  
"synonym": {  
"filter": [  
"synonym"  
],  
"tokenizer": "whitespace"  
}  
}  
},

--mapping

"BrandDesc": {  
"type": "string",  
"index": "not\_analyzed",  
"analyzer": "synonym",  
"fields": {  
"raw": {  
"type": "string",  
"analyzer": "synonym"  
}  
}  
},

whe i search with the query with normal query string

GET newpcdb\_anlyz/\_search  
{  
"query": {  
"query\_string": {  
"query": "engine"  
}  
}  
}

its giving me count say 1200

but same when i query with analyzer synonyms its giving me less count,(it should give more than 1200 as it will include engine synonyms also in search)

GET newpcdb\_anlyz/\_search  
{  
"query": {  
"query\_string": {  
"query": "engine",  
"analyzer": "synonym"  
}  
}  
}

Iam I missing something

---

<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:** [December 27, 2016, 3:15pm UTC](https://discuss.elastic.co/t/search-with-analyzer/67507/2 "2016-12-27T15:15:50Z")

</div>

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