# Multiple field formatters

**URL:** <https://discuss.elastic.co/t/multiple-field-formatters/261468>\
**Category:** Kibana\
**Created:** [January 18, 2021, 8:03pm UTC](https://discuss.elastic.co/t/multiple-field-formatters/261468 "2021-01-18T20:03:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![pfennema](https://avatars.discourse-cdn.com/v4/letter/p/58f4c7/32.png) [@pfennema](https://discuss.elastic.co/u/pfennema)\
**Post date:** [January 18, 2021, 8:03pm UTC](https://discuss.elastic.co/t/multiple-field-formatters/261468/1 "2021-01-18T20:03:26Z")

</div>

I currently have a dashboard (thanks to the enhanced table plugin) which shows a percentage in the table. The percentage is calculated by combining 2 fields into a scripted field ('percentage'). If the percentage is below 50% I'd like to have text in red, between 50%-75% in yellow and above 75% it will be green. This is quite easy to do with the colour formatter. However, then I cannot control the number of decimals (e.g. 2 decimals). So I'm now facing either have the colours and have the percentage shown with 10 decimals, or no colours and have 2 decimals as then I can use the number formatter. How can I have them both? I searched quite a bit for a solution but unfortunately no 'easy' solution apart from create my own custom field formatter plugin.

Thanks, Paul

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [January 19, 2021, 2:24am UTC](https://discuss.elastic.co/t/multiple-field-formatters/261468/2 "2021-01-19T02:24:12Z")

</div>

Welcome to our community! 😃

This looks like a [community based plugin](https://github.com/fbaligand/kibana-enhanced-table), so it might be worth chatting to the author of this plugin and seeing if it's something they can directly assist with.

Otherwise, someone else might have another option.

---

<div class="post-metadata">

**Author:** ![pfennema](https://avatars.discourse-cdn.com/v4/letter/p/58f4c7/32.png) [@pfennema](https://discuss.elastic.co/u/pfennema)\
**Post date:** [January 19, 2021, 9:53am UTC](https://discuss.elastic.co/t/multiple-field-formatters/261468/3 "2021-01-19T09:53:58Z")

</div>

Hi Mark,

It is indeed about the 'enhanced datatable - pivot table' from Fabien Baligand. However, the issue is more general I think. When a field formatter is applied via the index pattern you can only apply one. In this case I'd like to have only 2 decimals behind the decimal point **and** want to apply the color ranges. This is I think a general issue which has nothing to do with a plug-in as in every visualisation can have this issue I think. If there is a workaround for this, please let us know!  
The same question has been asked at least 2 times more, one is about how to modify the color formatter to have the rounding in there: [Modification of Color field formatter](https://discuss.elastic.co/t/modification-of-color-field-formatter/89751)

---

<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:** [February 16, 2021, 9:54am UTC](https://discuss.elastic.co/t/multiple-field-formatters/261468/4 "2021-02-16T09:54:06Z")

</div>

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