# Inner\_hits segment omitted while querying with elasticsearch-hadoop

**URL:** <https://discuss.elastic.co/t/inner-hits-segment-omitted-while-querying-with-elasticsearch-hadoop/265464>\
**Category:** Elasticsearch\
**Tags:** es-hadoop\
**Created:** [February 25, 2021, 10:35am UTC](https://discuss.elastic.co/t/inner-hits-segment-omitted-while-querying-with-elasticsearch-hadoop/265464 "2021-02-25T10:35:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![siddharthsourabh](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/siddharthsourabh/32/84528_2.png) [@siddharthsourabh](https://discuss.elastic.co/u/siddharthsourabh)\
**Post date:** [February 25, 2021, 10:35am UTC](https://discuss.elastic.co/t/inner-hits-segment-omitted-while-querying-with-elasticsearch-hadoop/265464/1 "2021-02-25T10:35:00Z")

</div>

A query with `inner_hits` is only returning the `_source` segment from within all the `hits`, and the `inner_hits` are being ignored. The ScrollReader only has logic to extract `_source` & `id` fields, see here - [elasticsearch-hadoop/ScrollReader.java at 0db74fdf51ef96f43b8648e6d1116a4a39469ee1 · elastic/elasticsearch-hadoop · GitHub](https://github.com/elastic/elasticsearch-hadoop/blob/0db74fdf51ef96f43b8648e6d1116a4a39469ee1/mr/src/main/java/org/elasticsearch/hadoop/serialization/ScrollReader.java#L283)

Can this be expanded to support inner\_hits segment as well?

---

<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 25, 2021, 10:35am UTC](https://discuss.elastic.co/t/inner-hits-segment-omitted-while-querying-with-elasticsearch-hadoop/265464/2 "2021-03-25T10:35:51Z")

</div>

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