# Extracting text within () from title to albumartist

**URL:** https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269
**Category:** Support
**Created:** [August 22, 2022, 12:57am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269 "2022-08-22T00:57:54Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![Ocalvopina](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/7ab992/32.png) [@Ocalvopina](https://community.mp3tag.de/u/Ocalvopina)
#### Post date: [August 22, 2022, 12:57am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/1 "2022-08-22T00:57:54Z")

</div>

Hello, I have used MP3TAG to manually edit individual files but now I have a lot of Mashup files whose title have text like the following. (artist1 vs artist2 vs artist3). I would like to extract the text and then copy to album artist. I would also like to remove the text from original title as well. I looked but as I have never done scripting it is not clear. I even saw some listings that said variable length gets would not be possible. Is this simple and I am missing something. Also I have looked at help files but examples don't seem to fit what I want to do. Is there a separate tutorial? or a you tube video? I can do manually but since i am now retired I really want to learn how to use this great product. Thank you in advance.

---

<div class="post-metadata">

### Author: ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)
#### Post date: [August 22, 2022, 5:56am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/2 "2022-08-22T05:56:55Z")

</div>

> [@Ocalvopina](#):
>
> I would like to extract the text and then copy to album artist.

Please show us a real example how your TITLE looks currently and how you would like to have filled the ALBUMARTIST tag.  
Something like this:  
TITLE `Kontra K (vs Sido) vs Leony`  
ALBUMARTIST: `Kontra K; Sido; Leony`  
or  
ALBUMARTIST: `Kontra K\\Sido\\Leony`

---

<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: [August 22, 2022, 6:24am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/3 "2022-08-22T06:24:31Z")

</div>

As you are very vague what the strings look like I can only direct you to the thread that also includes the link to the "swiss army knife" to move text around:

> [@Replace multiple tag fields, remove words](https://community.mp3tag.de/t/replace-multiple-tag-fields-remove-words/43670):
>
> Hello, I would like to remove from all TITLE tags the following words, (feat.\*) Basically if the title field has any words that begin with feat and enclosed in parenthesis, i.e. (feat.\*) then remove it. I tried using the Actions to create a preset, Replace with Regular Expression,but I can't get it to work Any help is appreciated

---

<div class="post-metadata">

### Author: ![Ocalvopina](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/7ab992/32.png) [@Ocalvopina](https://community.mp3tag.de/u/Ocalvopina)
#### Post date: [August 22, 2022, 6:50am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/4 "2022-08-22T06:50:46Z")

</div>

Thank you for your offer to help. I have mashup files that have TITLE like this:  
Name of song (artist1 vs. artist2)  
Sometimes there are even more listed artists. When I do manually I just select the text from parenthesis to parenthesis and then cut and paste to ALBUMARTIST field. I was hoping to automate this as the files have same format. Musicbee which I am using for my mashup files allows for searching on names in ALBUMARTIST field. I have seen people use ; and // as separators is there an advantage to doing this? As I had been doing manually I had left the formatting alone.  
I guess I am too new and the syntax in examples don’t make sense to me yet. I was hoping if someone would show me how to do this I could reverse engineer and learn the syntax of text scripting. Or if someone can point me in direction of very basic examples I can learn by example. Again thank you in advance for your help

---

<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: [August 22, 2022, 7:02am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/5 "2022-08-22T07:02:57Z")

</div>

As you are new, I would suggest that you use the Convert function, in this case: Convert\>Tag-Tag for ALBUMARTIST  
Format string: `%albumartist% $regexp(%title%,.*\((.*)\),$1)`  
This should copy the part in parenthesis to ALBUMARTIST

To remove the copied part, use Convert\>Tag-Tag for TITLE  
Format string: `$regexp(%title%,(.*)\(.*\),$1)`

The converter has a preview, so you should see immediately whether it leads to the desired result.

---

<div class="post-metadata">

### Author: ![Ocalvopina](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/7ab992/32.png) [@Ocalvopina](https://community.mp3tag.de/u/Ocalvopina)
#### Post date: [August 22, 2022, 7:16am UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/6 "2022-08-22T07:16:56Z")

</div>

Thank you I will try it in the morning as it is 2 AM for me here in Chicago.

---

<div class="post-metadata">

### Author: ![Ocalvopina](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/o/7ab992/32.png) [@Ocalvopina](https://community.mp3tag.de/u/Ocalvopina)
#### Post date: [August 22, 2022, 3:14pm UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/7 "2022-08-22T15:14:16Z")

</div>

Thank you that did work!

---

<div class="post-metadata">

### Author: ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)
#### Post date: [September 21, 2022, 3:14pm UTC](https://community.mp3tag.de/t/extracting-text-within-from-title-to-albumartist/58269/8 "2022-09-21T15:14:57Z")

</div>

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