# Update Kibana Filter from Vega

**URL:** <https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598>\
**Category:** Kibana\
**Tags:** vega\
**Created:** [January 27, 2022, 3:40pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598 "2022-01-27T15:40:18Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![TUKTUK](https://avatars.discourse-cdn.com/v4/letter/t/77aa72/32.png) [@TUKTUK](https://discuss.elastic.co/u/TUKTUK)\
**Post date:** [January 27, 2022, 3:40pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598/1 "2022-01-27T15:40:18Z")

</div>

Hello all,

I am quite new to the Vega world inside Kibana and would like to make a Vega visualization interactive so that the Kibana filters are updated on click.  
I have seen the following tutorial --\> [Update Timefilter from Vega](([Vega - Tutorial: Updating Kibana filters from Vega - 《Kibana v7.9 Guide》 - 书栈网 · BookStack](https://www.bookstack.cn/read/kibana-7.9-en/c01a7922bb2496f3.md))

The challenge now is that I don't want to filter on the Time field, but on other fields and don't know how to address them in the Signals. In the tutorial, I understand that the time is set/filtered with the "SetTimeFilter" function in the following code snippet.

 ![Signals Update Time Filter](https://us1.discourse-cdn.com/elastic/original/3X/f/4/f4a5f3675688f1586972b9a5e85829f7da5df2b0.png)

I took the code from the tutorial and adapted it analogously for my data. The graphic is clickable but the update in the signals fails obviously because I do not pass any date.

 ![Top News Vega](https://us1.discourse-cdn.com/elastic/original/3X/1/c/1cd6102ea06a0129e5639bce8637fa6764fe29d7.png)

So the question is which kind of other functions are available and how can I update/filter for my Keyword-Field "News".

Many thanks!

---

<div class="post-metadata">

**Author:** ![Tomo\_M](https://avatars.discourse-cdn.com/v4/letter/t/848f3c/32.png) [@Tomo\_M](https://discuss.elastic.co/u/Tomo_M)\
**Post date:** [January 27, 2022, 4:13pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598/2 "2022-01-27T16:13:32Z")

</div>

See [Here](https://www.elastic.co/guide/en/kibana/7.9/vega-reference.html#vega-queries).

You can retrieve the filter clause of dashboard context to set in query.

---

<div class="post-metadata">

**Author:** ![TUKTUK](https://avatars.discourse-cdn.com/v4/letter/t/77aa72/32.png) [@TUKTUK](https://discuss.elastic.co/u/TUKTUK)\
**Post date:** [February 2, 2022, 4:41pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598/3 "2022-02-02T16:41:47Z")

</div>

thanks for your response but I was looking for the other way round. I wanted to add a filter when clicking on one of the bars.  
"KibanaAddfilter(Query, Index)" did the job.

---

<div class="post-metadata">

**Author:** ![Tomo\_M](https://avatars.discourse-cdn.com/v4/letter/t/848f3c/32.png) [@Tomo\_M](https://discuss.elastic.co/u/Tomo_M)\
**Post date:** [February 2, 2022, 5:12pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598/4 "2022-02-02T17:12:46Z")

</div>

Sorry for misunderstanding. Im happy to hear you resolved the problem!

---

<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 2, 2022, 5:13pm UTC](https://discuss.elastic.co/t/update-kibana-filter-from-vega/295598/5 "2022-03-02T17:13:02Z")

</div>

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