# Dynamic fields and searches

**URL:** https://discuss.elastic.co/t/dynamic-fields-and-searches/124614
**Category:** Elasticsearch
**Created:** [March 19, 2018, 5:14pm UTC](https://discuss.elastic.co/t/dynamic-fields-and-searches/124614 "2018-03-19T17:14:44Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![xsallowed](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/xsallowed/32/28971_2.png) [@xsallowed](https://discuss.elastic.co/u/xsallowed)
#### Post date: [March 19, 2018, 5:14pm UTC](https://discuss.elastic.co/t/dynamic-fields-and-searches/124614/1 "2018-03-19T17:14:44Z")

</div>

Hi  
I am new to elasticsearch and lucene and trying to get my hands dirty with the data searches and the capability it provides in general. I am wondering if there is a way to create new fields in the documents as a result of search query. For example I have an index that has three fields username, email address and region. I want to create a fourth field highlighting the "domain name" which will be derived from "email address" field. If a user has email address [abc@yahoo.com](mailto:abc@yahoo.com), my fourth field should have "[yahoo.com](http://yahoo.com)" stored.

Any help?

Regards  
~Xs

---

<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 16, 2018, 5:15pm UTC](https://discuss.elastic.co/t/dynamic-fields-and-searches/124614/2 "2018-04-16T17:15:16Z")

</div>

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