# Scripted field issue

**URL:** <https://discuss.elastic.co/t/scripted-field-issue/120307>\
**Category:** Kibana\
**Created:** [February 17, 2018, 1:35pm UTC](https://discuss.elastic.co/t/scripted-field-issue/120307 "2018-02-17T13:35:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric\_Yin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/eric_yin/32/33098_2.png) [@Eric\_Yin](https://discuss.elastic.co/u/Eric_Yin)\
**Post date:** [February 17, 2018, 1:35pm UTC](https://discuss.elastic.co/t/scripted-field-issue/120307/1 "2018-02-17T13:35:11Z")

</div>

Dear ELK developers,

I would like to ask if there is any feature to involve putting the scripted field by txt or by other format to import the scripted field since we have thounsands of KPIs and we involve thounsands of formula(scripted fields) to calculate based on those fields.

May I know where the scripted field in kibana page stored? it is stored into the ES DB or stored into some configuration file, I failed to find my added scripted field on the backend server. Please kindly adivse

---

<div class="post-metadata">

**Author:** ![bhavyarm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bhavyarm/32/22392_2.png) [@bhavyarm](https://discuss.elastic.co/u/bhavyarm)\
**Post date:** [February 20, 2018, 3:29pm UTC](https://discuss.elastic.co/t/scripted-field-issue/120307/2 "2018-02-20T15:29:27Z")

</div>

Hi Eric,

Scripted fields are stored in index patterns in .kibana index.

Thanks,  
Bhavya

---

<div class="post-metadata">

**Author:** ![Eric\_Yin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/eric_yin/32/33098_2.png) [@Eric\_Yin](https://discuss.elastic.co/u/Eric_Yin)\
**Post date:** [February 21, 2018, 6:20am UTC](https://discuss.elastic.co/t/scripted-field-issue/120307/3 "2018-02-21T06:20:48Z")

</div>

Hello,

Thanks for your reply.  
curl -XGET '[http://127.0.0.1:9200/.kibana/\_search?pretty](http://127.0.0.1:9200/.kibana/_search?pretty)'  
I can find the scripted field with other field/dashboard definition from .kibana. May I know how to update this index by add new scripted field from the backend restful API? Is there any example?

{"name":"test\_scripted\_field","type":"number","count":0,"scripted":true,"script":"doc['EUtranCellFDD.pmRrcConnMax'].value","lang":"painless","indexed":false,"analyzed":false,"doc\_values":false,"searchable":true,"aggregatable":true}

I just would like to read an formula text and tranform it into the .kibana automatically instead of add them mannually one by one. I guess if I create a new index paterns, there might be a way to copy the pervious index configuration(dashabord,scripted field ..) into a new one through restful API. Kindly advice, thank you very much

---

<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 21, 2018, 6:21am UTC](https://discuss.elastic.co/t/scripted-field-issue/120307/4 "2018-03-21T06:21:05Z")

</div>

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