# Add a new field to the template index and aggregate on it

**URL:** <https://discuss.elastic.co/t/add-a-new-field-to-the-template-index-and-aggregate-on-it/80300>\
**Category:** Elasticsearch\
**Created:** [March 28, 2017, 1:02pm UTC](https://discuss.elastic.co/t/add-a-new-field-to-the-template-index-and-aggregate-on-it/80300 "2017-03-28T13:02:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![korsdecaying](https://avatars.discourse-cdn.com/v4/letter/k/dbc845/32.png) [@korsdecaying](https://discuss.elastic.co/u/korsdecaying)\
**Post date:** [March 28, 2017, 1:02pm UTC](https://discuss.elastic.co/t/add-a-new-field-to-the-template-index-and-aggregate-on-it/80300/1 "2017-03-28T13:02:48Z")

</div>

I'm trying to add an additional template to elasticsearch to parse the dns packetbeat. The template adds an additional package analysis field.

```
-XPUT HTTP://localhost:9200/_template/packetbeat-* -d@packetbeat-dns-template.json

result
{"acknowledged":true}

```

When you start a kiban and choose a strategy, it determines this field in the list

 ![](https://us1.discourse-cdn.com/elastic/original/3X/b/4/b4bee3dd35e6d47076b3036409acf9dadf631ded.png)

But in the future when you visualize and aggregate the records of the table of this field is not in the list.As I understand it, I need to check the aggregation check box, but how do I do this?

---

<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:** [April 25, 2017, 1:03pm UTC](https://discuss.elastic.co/t/add-a-new-field-to-the-template-index-and-aggregate-on-it/80300/2 "2017-04-25T13:03:20Z")

</div>

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