# Copy the value of a field into an event and paste it into another field and another event

**URL:** <https://discuss.elastic.co/t/copy-the-value-of-a-field-into-an-event-and-paste-it-into-another-field-and-another-event/87639>\
**Category:** Logstash\
**Created:** [May 30, 2017, 9:42pm UTC](https://discuss.elastic.co/t/copy-the-value-of-a-field-into-an-event-and-paste-it-into-another-field-and-another-event/87639 "2017-05-30T21:42:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rocavalcante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rocavalcante/32/18648_2.png) [@rocavalcante](https://discuss.elastic.co/u/rocavalcante)\
**Post date:** [May 30, 2017, 9:42pm UTC](https://discuss.elastic.co/t/copy-the-value-of-a-field-into-an-event-and-paste-it-into-another-field-and-another-event/87639/1 "2017-05-30T21:42:32Z")

</div>

Hi Everyone,

My doubt is for example:

{  
"offset" =\> 7,  
"word1" =\> "XPTO", \<- Copy this value  
"@metadata" =\> {  
"beat" =\> "filebeat",  
"type" =\> "log"  
},  
"input\_type" =\> "log",  
"source" =\> "mylog.txt",  
"message" =\> "XPTO,",  
"type" =\> "log",  
"mac" =\> "1512150Z000",  
"tags" =\> [  
[0] "beats\_input\_codec\_plain\_applied",  
[1] "\_grokparsefailure"  
],  
"second" =\> "50",  
"datetime" =\> "04/20/2017 06:13",  
"@timestamp" =\> 2017-05-30T21:13:37.982Z,  
"@version" =\> "1",  
"beat" =\> {  
"hostname" =\> "my-PC",  
"name" =\> "my-PC",  
"version" =\> "5.4.0"  
},  
"host" =\> "my",  
"t1" =\> "SFCS",  
"t2" =\> "MAC"  
}  
{  
"offset" =\> 17,  
"@metadata" =\> {  
"beat" =\> "filebeat",  
"type" =\> "log"  
},  
"input\_type" =\> "log",  
"word3" =\> "A0000",  
"word2" =\> "NG",  
"word1" =\> "XPTO", \<- Paste Value . (This field does not exist at this event)  
"source" =\> "mylog.txt",  
"message" =\> "NG,A0000",  
"type" =\> "log",  
"mac" =\> "1512150Z000",  
"tags" =\> [  
[0] "beats\_input\_codec\_plain\_applied",  
[1] "\_grokparsefailure"  
],  
"second" =\> "50",  
"datetime" =\> "04/20/2017 06:13",  
"@timestamp" =\> 2017-05-30T21:13:37.982Z,  
"@version" =\> "1",  
"beat" =\> {  
"hostname" =\> "my-PC",  
"name" =\> "my-PC",  
"version" =\> "5.4.0"  
},  
"host" =\> "my-PC",  
"t1" =\> "SFCS",  
"t2" =\> "MAC"  
}

I'm using ELK 5.4  
Filebeat and Logstash;

---

<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 27, 2017, 9:42pm UTC](https://discuss.elastic.co/t/copy-the-value-of-a-field-into-an-event-and-paste-it-into-another-field-and-another-event/87639/2 "2017-06-27T21:42:35Z")

</div>

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