# Unexpected results when filtering docs in nested field

**URL:** <https://discuss.elastic.co/t/unexpected-results-when-filtering-docs-in-nested-field/304960>\
**Category:** Elasticsearch\
**Created:** [May 17, 2022, 3:32pm UTC](https://discuss.elastic.co/t/unexpected-results-when-filtering-docs-in-nested-field/304960 "2022-05-17T15:32:29Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![RabBit\_BR](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rabbit_br/32/82261_2.png) [@RabBit\_BR](https://discuss.elastic.co/u/RabBit_BR)\
**Post date:** [May 17, 2022, 4:34pm UTC](https://discuss.elastic.co/t/unexpected-results-when-filtering-docs-in-nested-field/304960/2 "2022-05-17T16:34:00Z")

</div>

Hi!!

This post is a little similar:

> [@Elasticsearch must\_not on all elements in array](https://discuss.elastic.co/t/elasticsearch-must-not-on-all-elements-in-array/138390/5):
>
> Hi, thanks! Abdon this would be ok, but I would need to reindex all the items (which are in millions of large items and takes days). Tamara yours looks easier but how to scripted filters affect performance? If it's a big performance hit it might still be better to reindex my items.

Perhaps the solution is to use a script.

---

_[View the full topic](https://discuss.elastic.co/t/unexpected-results-when-filtering-docs-in-nested-field/304960)._
