Stat Panel with specific field value

Hi all,

I have index with following mapping

{ "mappings": { "properties": { "@timestamp": { "type": "date" }, "kpi-data": { "type": "nested", "properties": { "id": { "type": "text" }, "name": { "type": "text" }, "value": { "type": "double" } } }, "project_key": { "type": "text" } } } }
I want to create stat panel. Each box need to display the latest value of document with kpi-data.id:performance-*. The header of each box display the kpi-data.name.

I try to do lucene query project-key:"My Project" AND kpi-data.id:performance-* but it’s only showing 0 value.

Thank You

Does properties come before id?

Hi @yosiasz ,

I’m not sure if I understand your question.
Following is sample of data available on elastic:

> "_source":
> 	{
> 	"project-key":"My Project",
> 	"kpi-data":{
> 		"name":"Performance Get Data",
> 		"id":"performance-get-data",
> 		"value":111.48063438845726},
> 	"@timestamp":"2023-11-28T05:17:18.541219856Z"}},
> "_source":{"
> 	project-key":
> 	"My Project",
> 	"kpi-data":{
> 		"name":"Performance Update Data",
> 		"id":"performance-update-data",
> 		"value":36.783606810750555},
> "@timestamp":"2023-11-28T05:17:19.226401834Z"}}

your original post had this

"kpi-data": {
	"type": "nested",
	"properties": {
		"id": {
			"type": "text"
		},

kpi-data.properties.id

I highly recommend you use infinity plugin and hit the ES enpoint 9200