# How I can get 2 fields values in Elastic Search

**URL:** <https://discuss.elastic.co/t/how-i-can-get-2-fields-values-in-elastic-search/384419>\
**Category:** Kibana\
**Created:** [January 7, 2026, 4:42pm UTC](https://discuss.elastic.co/t/how-i-can-get-2-fields-values-in-elastic-search/384419 "2026-01-07T16:42:32Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Tortoise](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tortoise/32/147587_2.png) [@Tortoise](https://discuss.elastic.co/u/Tortoise)\
**Post date:** [January 8, 2026, 11:32am UTC](https://discuss.elastic.co/t/how-i-can-get-2-fields-values-in-elastic-search/384419/4 "2026-01-08T11:32:26Z")

</div>

Hello @SivaK

You will have to create a runtime field from this .keyword field if you want to perform sum on keyword fields.

Similar post :

> [@Can I do a sum on the fields that have 'keyword' type](https://discuss.elastic.co/t/can-i-do-a-sum-on-the-fields-that-have-keyword-type/333076):
>
> I have a field that is keyword type. The index looks like this: { "key": 1 }, { "key": 2 }, { "key": 3 }, { "key":"abc" }, { "key":"zyx" } Some values are numeric and some are strings. Is there a way to sum all numeric keywords such that the value comes to 1+2+3 = 6 Is some form type casting possible?

Thanks!!

---

_[View the full topic](https://discuss.elastic.co/t/how-i-can-get-2-fields-values-in-elastic-search/384419)._
