# Results Component not working: Result.id is undefined

**URL:** <https://discuss.elastic.co/t/results-component-not-working-result-id-is-undefined/287696>\
**Category:** Elastic Search\
**Tags:** elastic-app-search\
**Created:** [October 26, 2021, 12:59pm UTC](https://discuss.elastic.co/t/results-component-not-working-result-id-is-undefined/287696 "2021-10-26T12:59:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Julian\_Hesse](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/julian_hesse/32/96369_2.png) [@Julian\_Hesse](https://discuss.elastic.co/u/Julian_Hesse)\
**Post date:** [October 26, 2021, 12:59pm UTC](https://discuss.elastic.co/t/results-component-not-working-result-id-is-undefined/287696/1 "2021-10-26T12:59:46Z")

</div>

I used the search-ui example "elasticsearch". Then I adjusted everything to the Elasticsearch setup I have (different fields and facets).  
Mostly everything worked out fine. Except that when I actually get results the app crashes with the error "Uncaught TypeError: result.id is undefined".  
Unlike the example my results have the field "uuid" instead of "id". I think that is the root of the problem. The

My code for "Results":

```auto
                bodyContent={
                  <Results
                    titleField="document.title"
                    urlField="document.url"
                    shouldTrackClickThrough={true}
                  />
                }

```

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/d/c/dca6c260f778556f2ad6fb44a4c88df3c55cd357.png)

Is there a way to make it work with the field "uuid"?

I am really stuck at fixing this. Any help would be great 🙂

---

<div class="post-metadata">

**Author:** ![JasonStoltz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jasonstoltz/32/49893_2.png) [@JasonStoltz](https://discuss.elastic.co/u/JasonStoltz)\
**Post date:** [October 26, 2021, 1:25pm UTC](https://discuss.elastic.co/t/results-component-not-working-result-id-is-undefined/287696/2 "2021-10-26T13:25:55Z")

</div>

You'll either need to add an `id` field to your result object (this is probably the easiest option), or customize the `Result` view to look for `uuid` instead of `id`: [Reference UI - how to modify what's displayed (React newbie) - #2 by JasonStoltz](https://discuss.elastic.co/t/reference-ui-how-to-modify-whats-displayed-react-newbie/199471/2)

---

<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:** [November 23, 2021, 1:25pm UTC](https://discuss.elastic.co/t/results-component-not-working-result-id-is-undefined/287696/3 "2021-11-23T13:25:59Z")

</div>

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