Creating a percentage metric from 2 different indexes

Hi Everyone,

I am trying to create a metric visualization that would show me a percentage. The issue that that the values are from 2 different indexes.

Let's say the first index is called 'phishing_emails_reported' and the second is 'phishing_emails_blocked'. I want to count the number of documents in 'phishing_emails_reported' (lets call this x) and count the number of docs in 'phishing_emails_blocked' (lets call this y). I want to return the value of 1 - x/y

I have tried using some bucket script aggregations to no avail.

Is there a way to have an aggregation fetch data from 2 different indexes or have 2 separate (sibling pipeline?) aggregations that would do this?

I believe that I can do this is timelion but I don't want a graph but rather a single percentage that I can but on a dashboard.

Thank you!

Hey @tyler_hilsabeck, this isn't possible until https://github.com/elastic/kibana/issues/4707 is implemented. If you can give this a +1 or comment with your specific needs, it'll help us prioritize it appropriately.

Hi @Brandon_Kobel, thank you for the help. This is something I would like to see. Specifically I would like to be able to compare data from 2 indexes.