# How to change the indices specified by the index pattern？

**URL:** <https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248>\
**Category:** Kibana\
**Created:** [May 6, 2020, 4:15am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248 "2020-05-06T04:15:34Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Echo\_yu](https://avatars.discourse-cdn.com/v4/letter/e/e5b9ba/32.png) [@Echo\_yu](https://discuss.elastic.co/u/Echo_yu)\
**Post date:** [May 6, 2020, 4:15am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/1 "2020-05-06T04:15:34Z")

</div>

Hi，could I change the indices which are specified by the created index pattern？Or Can I change the index pattern specified by viualization？Looking forward to your reply，Thanks！

---

<div class="post-metadata">

**Author:** ![dosant](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dosant/32/64489_2.png) [@dosant](https://discuss.elastic.co/u/dosant)\
**Post date:** [May 6, 2020, 12:13pm UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/2 "2020-05-06T12:13:05Z")

</div>

Hi @Echo_yu

> Can I change the index pattern specified by visualisation

This is possible.  
as of 7.6.2:  
Go to Management -\> Kibana -\> Saved Objects  
Pick visualisation you want to fix, Actions -\> Inspect.  
Please be careful in this area, read through the warnings.

In the bottom you'd see `references` field.

To update index pattern reference you'd add something like this:  
`[{"id":"id-of-your-new-index-pattern","name":"kibanaSavedObjectMeta.searchSourceJSON.index","type":"index-pattern"}]`

You can get the id of you new index pattern, for example, from the URL from the page where you manage that index pattern.

Or you could do it by exporting visualisation saved object, modifying `references` field, and then importing it back

Hope this is helpful.

---

<div class="post-metadata">

**Author:** ![Echo\_yu](https://avatars.discourse-cdn.com/v4/letter/e/e5b9ba/32.png) [@Echo\_yu](https://discuss.elastic.co/u/Echo_yu)\
**Post date:** [May 7, 2020, 3:26am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/3 "2020-05-07T03:26:04Z")

</div>

It is very helpful to me，Thank you so much！

---

<div class="post-metadata">

**Author:** ![dosant](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dosant/32/64489_2.png) [@dosant](https://discuss.elastic.co/u/dosant)\
**Post date:** [May 15, 2020, 11:27am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/4 "2020-05-15T11:27:24Z")

</div>

Hi @Echo_yu,

Just wanted to let you know that there is a known bug in recently released 7.7.0 with editing saved object using inspect.

> <https://github.com/elastic/kibana/pull/66612>

Please be even more careful with trying this in 7.7.0 and backup your SavedObjects (at least locally using export functionality) before doing changes in that area.

---

<div class="post-metadata">

**Author:** ![Echo\_yu](https://avatars.discourse-cdn.com/v4/letter/e/e5b9ba/32.png) [@Echo\_yu](https://discuss.elastic.co/u/Echo_yu)\
**Post date:** [June 4, 2020, 2:48am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/5 "2020-06-04T02:48:06Z")

</div>

Thanks for your reminding，I will be more careful with trying this in 7.7.0.

---

<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 2, 2020, 2:48am UTC](https://discuss.elastic.co/t/how-to-change-the-indices-specified-by-the-index-pattern/231248/6 "2020-07-02T02:48:18Z")

</div>

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