# Override field value for sorting

**URL:** <https://discuss.elastic.co/t/override-field-value-for-sorting/89339>\
**Category:** Elasticsearch\
**Created:** [June 14, 2017, 9:06am UTC](https://discuss.elastic.co/t/override-field-value-for-sorting/89339 "2017-06-14T09:06:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Strato](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@Strato](https://discuss.elastic.co/u/Strato)\
**Post date:** [June 14, 2017, 9:06am UTC](https://discuss.elastic.co/t/override-field-value-for-sorting/89339/1 "2017-06-14T09:06:41Z")

</div>

Konishiwa amigos,

I have the following requirement : I have a field, that contains a priority term (string) : highest, high, medium, low, lowest. I want to be able to sort on this field, but not by alphabetical order. I want to say to ES that highest has an higher sorting score than high, etc.

Is it possible? Can I somehow apply a score to sort terms? Maybe in the mapping?

---

<div class="post-metadata">

**Author:** ![Strato](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@Strato](https://discuss.elastic.co/u/Strato)\
**Post date:** [June 22, 2017, 12:30pm UTC](https://discuss.elastic.co/t/override-field-value-for-sorting/89339/2 "2017-06-22T12:30:29Z")

</div>

No? Not the slighest idea?

---

<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:** [July 20, 2017, 12:30pm UTC](https://discuss.elastic.co/t/override-field-value-for-sorting/89339/3 "2017-07-20T12:30:36Z")

</div>

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