Adding Variable - Query for Tags

I am trying to have a filter applied for my dashboard where i want “JVM” to be in the drop down list. I’m not able to figure out the right query for this. Below is my data - Could you please help.

Grafana - 5.2.4
Measurement name - statsdata
db name - testdb

json_body = [
        {
            "measurement": "statsdata",
            "tags": {
                "JVM": "server_qa"    // multiple JVMs with different name formats
            },
            "time": timestamp,
            "fields": {
                "PID": 11283,
				"CPU": 44.5,
				"MEM": 5.2
				
            }
        }
    ]

What should i be updating the Query section (image 1) so that a drop down of JVMs will be visible in the my dashboard (image 2, sample example). I tried the the query - SHOW TAG VALUES FROM STATSDATA WITH KEY = “JVM” but no results were returned. Please clarify.

Untitled1