# Capture from one field and transfer to another

**URL:** https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587
**Category:** General Discussion
**Created:** [February 8, 2015, 11:51pm UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587 "2015-02-08T23:51:34Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![bmacd615](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/b/d26b3c/32.png) [@bmacd615](https://community.mp3tag.de/u/bmacd615)
#### Post date: [February 8, 2015, 11:51pm UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/1 "2015-02-08T23:51:34Z")

</div>

I have some ability with regex. Can I pull some data out of one field and then paste it into another field?

For example the Title field contains BWV 100. I have made a BWV field and I want to pull that data out of the Title field and populate the BWV field.

Updated: Since originally posting I have now realized I can copy the title field to the BWV and then delete down to what I need.  
Is there a better way?

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [February 9, 2015, 7:23am UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/2 "2015-02-09T07:23:16Z")

</div>

> [@bruce615](#):
>
> ... Since originally posting I have now realized I can copy the title field to the BWV and then delete down to what I need. Is there a better way?

Sometimes Mp3tag offers different ways to reach the goal, ...  
this depends on the input data and the skill of the user.

DD.20150209.0923.CET

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [February 9, 2015, 7:27am UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/3 "2015-02-09T07:27:29Z")

</div>

> [@DetlevD](#):
>
> Sometimes Mp3tag offers different ways to reach the goal, ...  
> this depends on the input data and the skill of the user.
> 
> DD.20150209.0923.CET

Exactly. Both true. Just to point into a direction, different from regualr expressions:  
What about an action of type "Guess value"? But for that one would have to know more about the data structure. As you said.

---

<div class="post-metadata">

### Author: ![bmacd615](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/b/d26b3c/32.png) [@bmacd615](https://community.mp3tag.de/u/bmacd615)
#### Post date: [February 10, 2015, 12:27am UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/4 "2015-02-10T00:27:56Z")

</div>

> [@ohrenkino](#):
>
> Exactly. Both true. Just to point into a direction, different from regualr expressions:  
> What about an action of type "Guess value"? But for that one would have to know more about the data structure. As you said.

Below are two examples of the Title field that contain the BWV number. The content of the Title field is not consistent over the 70 or so CDs

I want to copy that value and paste it in the BWV field I created. As I said, I am doing well enough by copying the entire Title field to my BWV field and then applying regular expressions. But is there a better way?

Cantata 'Wer nur den lieben Gott läßt walten' BWV93: VI. Aria 'Ich will auf den Herren schaun' (Soprano)

Bach: Cantata, BWV 90, "Es Reisset Euch Ein Schrecklich Ende" - Doch Gottes Auge Sieht Auf Uns

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [February 10, 2015, 7:45am UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/5 "2015-02-10T07:45:17Z")

</div>

> [@bruce615](#):
>
> Below are two examples of the Title field that contain the BWV number. The content of the Title field is not consistent over the 70 or so CDs  
> I want to copy that value and paste it in the BWV field I created. ...

**Filter: TITLE HAS "BWV" Action: Format value Field : BWV Formatstring: $regexp(%TITLE%,'^.\*\bBWV\s\*(\d+)\b.\*$','$1')**

... or without Filter ...

**Action: Format value Field : BWV Formatstring: $if($eql($regexp(%TITLE%,'^.\*\bBWV\s\*(\d+)\b.\*$',),),** 

**```
          <!--coloro:#800080--><span style="color:#800080"><!--/coloro-->$regexp<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->(<!--colorc--></span><!--/colorc--><!--coloro:#0000a0--><span style="color:#0000a0"><!--/coloro-->%TITLE%<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->,<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->'<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->^.*\bBWV\s*(\d+)\b.*$<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->'<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->,<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->'<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->$1<!--colorc--></span><!--/colorc--><!--coloro:#008080--><span style="color:#008080"><!--/coloro-->'<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->)<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->,<!--colorc--></span><!--/colorc--><!--coloro:#000000--><span style="color:#000000"><!--/coloro-->)<!--colorc--></span><!--/colorc--></b><!--fontc--></span><!--/fontc--><!--sizec--></span><!--/sizec-->**

**```**

 

DD.20150210.0954.CET

---

<div class="post-metadata">

### Author: ![JJ\_Johnson](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jj_johnson/32/67_2.png) [@JJ\_Johnson](https://community.mp3tag.de/u/JJ_Johnson)
#### Post date: [February 10, 2015, 7:13pm UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/6 "2015-02-10T19:13:57Z")

</div>

> [@bruce615](#):
>
> I want to copy that value and paste it in the BWV field I created. As I said, I am doing well enough by copying the entire Title field to my BWV field and then applying regular expressions. But is there a better way?

For a saved action group, that's a good approach. There's often no real advantage to doing it in one action vs. two or three, etc. By using multiple actions, you often make the process easier to both understand and edit if you go back later and need to change something.

---

<div class="post-metadata">

### Author: ![bmacd615](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/b/d26b3c/32.png) [@bmacd615](https://community.mp3tag.de/u/bmacd615)
#### Post date: [February 11, 2015, 12:45am UTC](https://community.mp3tag.de/t/capture-from-one-field-and-transfer-to-another/16587/7 "2015-02-11T00:45:02Z")

</div>

DetlevD,  
After looking at your posted solution I was going to say, we live on different planets! Then I saw you are on earth too. Hmm. The Bach of regular expressions.
