# How to apply fuzzy prefix matching on not\_analyzed child field

**URL:** <https://discuss.elastic.co/t/how-to-apply-fuzzy-prefix-matching-on-not-analyzed-child-field/134097>\
**Category:** Elasticsearch\
**Created:** [May 31, 2018, 6:25pm UTC](https://discuss.elastic.co/t/how-to-apply-fuzzy-prefix-matching-on-not-analyzed-child-field/134097 "2018-05-31T18:25:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Krishnapriya\_Mahajan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/krishnapriya_mahajan/32/58029_2.png) [@Krishnapriya\_Mahajan](https://discuss.elastic.co/u/Krishnapriya_Mahajan)\
**Post date:** [May 31, 2018, 6:25pm UTC](https://discuss.elastic.co/t/how-to-apply-fuzzy-prefix-matching-on-not-analyzed-child-field/134097/1 "2018-05-31T18:25:35Z")

</div>

Hi All,  
I am new to elasticsearch. I am having difficulty in construction of query that will do prefix match along with fuzziness on non-analyzed field that is a child field.

i have mapping like A has property B. B has Property C. C is not\_analyzed field. I need to do filter/search\_as\_you\_type thing on it.  
This works for me

{  
"query" : {  
"nested" : {  
"path": "A.B",  
"query": {  
"prefix": {  
"postcode": "W1"  
}  
}  
}  
}  
}

Sorry for not constructing question correctly.  
TIA

---

<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:** [June 28, 2018, 6:25pm UTC](https://discuss.elastic.co/t/how-to-apply-fuzzy-prefix-matching-on-not-analyzed-child-field/134097/2 "2018-06-28T18:25:37Z")

</div>

Closed on June 28, 2018, 6:25pm UTC

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