Is it possible to get the list of entries from ES to be queried in mysql and display as label?

Hi everyone,

I have ES, I was able to project the graph, I have a requirement where the plot entries(example an ID), should make another query to mysql for its entry for equivalent name and display it as a label instead of the ID from ES output.

Do you mean you have a query for Elasticsearch and you want a template variable (drop down) with a list of values from MySQL that you can use with your ES query? Or do you mean that you want to join the queries?

Can you show an example?

Thank you for the response and here is the Example: I have an IP address which is from elastic search and is a plot on a graph, Now I want to query MySQL database with IP list and display label which is the output of a query.

Sounds like it should work - was hoping you would show queries for mysql and elasticsearch so that I could give you more specific help. Did you get it to work?

Sure Thanks for checking it , here is the one which i am trying

MYSQL: select sample_value from mydb where hostIP = “”;

Elastic search: message=DOWN and env=prod group by host.ip

for the received host.ip’s I need to query DB and findout the sample_value and show in labels.