# Elasticsearch output format with "head" plugin

**URL:** <https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051>\
**Category:** Elasticsearch\
**Created:** [February 27, 2014, 1:07pm UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051 "2014-02-27T13:07:48Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prashant\_Pal](https://avatars.discourse-cdn.com/v4/letter/p/b77776/32.png) [@Prashant\_Pal](https://discuss.elastic.co/u/Prashant_Pal)\
**Post date:** [February 27, 2014, 1:07pm UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051/1 "2014-02-27T13:07:48Z")

</div>

Hi All,

I am using head plugin to access the elastic search through GUI and cluster plugin to cluster the data.  
So is there anyway I can display any particular field in GUI of elasticsearch.  
For ex:  
If my query is  
**{  
"search\_request": {  
"fields": [  
"Content"  
],  
"query": {  
"match": {  
"\_all": "mobile"  
}  
}  
},  
"field\_mapping": {  
"content": [  
"fields.Content"  
]  
},  
}**

And response will be everything as **took, size, data, label, clusters, phrases** etc.

So is there any way I can display only label/cluster in elasticsearch GUI with the help of any other plugin or other way out.

---

<div class="post-metadata">

**Author:** ![Prashant\_Pal](https://avatars.discourse-cdn.com/v4/letter/p/b77776/32.png) [@Prashant\_Pal](https://discuss.elastic.co/u/Prashant_Pal)\
**Post date:** [February 28, 2014, 8:57am UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051/2 "2014-02-28T08:57:35Z")

</div>

Any help for the same issue?

---

<div class="post-metadata">

**Author:** ![Binh\_Ly\_2](https://avatars.discourse-cdn.com/v4/letter/b/d07c76/32.png) [@Binh\_Ly\_2](https://discuss.elastic.co/u/Binh_Ly_2)\
**Post date:** [February 28, 2014, 1:19pm UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051/3 "2014-02-28T13:19:16Z")

</div>

If you're doing a \_search on the "Any Request" tab in head, there is a  
Result Transformer section at the bottom of your search query. In there you  
can write a simple transform script. For example, the following script  
displays only the took and the hits values:

return { took: root.took, hits: root.hits.hits };

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/8f05e015-3db9-4eaa-aa50-790647c59b1b%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/8f05e015-3db9-4eaa-aa50-790647c59b1b%40googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Prashant\_Pal](https://avatars.discourse-cdn.com/v4/letter/p/b77776/32.png) [@Prashant\_Pal](https://discuss.elastic.co/u/Prashant_Pal)\
**Post date:** [March 3, 2014, 6:21am UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051/4 "2014-03-03T06:21:15Z")

</div>

Hi Binh,

Actually I did the same but the problem is I want to fetch multiple record.

For ex.

1. There is query which returns multiple clusters and that clusters have labels.
2. Now I want to fetch the label from all clusters .
3. So if I am writing the query like return { label:root.clusters[0].label};
4. It will return the label for cluster 0.
5. But I want the label from all clusters so how I can achieve that?

---

<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:** [July 6, 2017, 1:46am UTC](https://discuss.elastic.co/t/elasticsearch-output-format-with-head-plugin/16051/5 "2017-07-06T01:46:17Z")

</div>


