# Display field-specific information individually

**URL:** <https://discuss.elastic.co/t/display-field-specific-information-individually/181368>\
**Category:** Kibana\
**Created:** [May 16, 2019, 10:27am UTC](https://discuss.elastic.co/t/display-field-specific-information-individually/181368 "2019-05-16T10:27:50Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Miao](https://avatars.discourse-cdn.com/v4/letter/m/8baadc/32.png) [@Miao](https://discuss.elastic.co/u/Miao)\
**Post date:** [May 16, 2019, 10:27am UTC](https://discuss.elastic.co/t/display-field-specific-information-individually/181368/1 "2019-05-16T10:27:50Z")

</div>

I have an index named `firedrill`. All documents in that index have a field named `DrillSteps`:

```auto
"DrillSteps": [
	{
		"Errors": [
			"Oven door opened before fuses were turned off."
		],
		"NumErrors": 1,
		"Name": "Fuses turned off."
	},
	{
		"Errors": [
			"Fuses turned on again before oven was safe",
			"Door was not closed again fast enough"
		],
		"NumErrors": 2,
		"Name": "Oven door closed again."
	},
	{
		"Errors": [
			"Oven opened before protective gear worn."
		],
		"NumErrors": 1,
		"Name": "Protective gear worn."
	},
	{
		"Errors": [],
		"NumErrors": 0,
		"Name": "Oven smoke died out."
	},
	{
		"Errors": [],
		"NumErrors": 0,
		"Name": "Burnt meal disposed of."
	}
]

```

All you can see, each step has a name, and a list of errors committed by the student when going through that particular step. Each drill step has a specific list of possible errors. E.g. the error "Oven opened before protective gear worn" is specific to the step "Protective gear worn".

I would like to create a graph, where the y-axis shows drill errors grouped by drill steps. **Importantly, drill errors that are not possible values for a drill step are not shown.** The x-axis should display the error count.

Currently, this is how I have defined my graph:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/0/0/008e71ae13960532bd45b6dc78dc105970afea97.png)

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/4/7/47ab8c68497b94b15722b8de6caad12fcd3998a4.png)

And this is the output:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/a/8/a8f22e85cf405968dc593f835adb848be99a7a1f.png)

The count on the x-axis refers to the document count.

As you can see, this is not what I want. I am obviously doing something wrong, so I would appreciate receiving feedback on what changes I must make (either to how I defined my graph or to how I designed the data schema) in order to display my desired graph.

If anything is unclear, please let me know and I will rephrase and/or provide more information.

---

<div class="post-metadata">

**Author:** ![thomasneirynck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/thomasneirynck/32/23313_2.png) [@thomasneirynck](https://discuss.elastic.co/u/thomasneirynck)\
**Post date:** [May 16, 2019, 2:54pm UTC](https://discuss.elastic.co/t/display-field-specific-information-individually/181368/2 "2019-05-16T14:54:27Z")

</div>

@Miao

I think you're running into an issue with your data not being de-normalized. I'm not sure you can express that query in Kibana on your nested datastructure.

You could re-index the data where each document is an actual tuple of step in the process/error at that step. Then you could create that chart with a similar configuration as you have now.

---

<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:** [June 17, 2019, 9:20am UTC](https://discuss.elastic.co/t/display-field-specific-information-individually/181368/4 "2019-06-17T09:20:00Z")

</div>

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