# Help with Duplicate Text

**URL:** <https://community.mp3tag.de/t/help-with-duplicate-text/60764>\
**Category:** Support\
**Created:** [April 21, 2023, 6:00pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764 "2023-04-21T18:00:39Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![JFollo](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/j/a9adbd/32.png) [@JFollo](https://community.mp3tag.de/u/JFollo)\
**Post date:** [April 21, 2023, 6:00pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/1 "2023-04-21T18:00:40Z")

</div>

Hello

I have been having a hard time finding information that would help me with the following problem.

I need to remove the 2nd (feat. and replace with & symbol.

Example:

Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx)

to

Mass Of Man - Unhappy (feat. Olivia Charlotte & Bingx)

Additionally if there is this type of problem, I would like to remove the last 2 (feat. and replace both with & symbol.

Example:

Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx (feat. Misc)

to

Mass Of Man - Unhappy (feat. Olivia Charlotte & Bingx & Misc)

A super wish would be to replace the 2nd (feat. with a comma and the 3rd (feat. with & (not sure if this would be possible)

Example:

Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx (feat. Misc)

to

Mass Of Man - Unhappy (feat. Olivia Charlotte, Bingx & Misc)

Hope someone can help  
Thank you very much

---

<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:** [April 21, 2023, 6:15pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/2 "2023-04-21T18:15:09Z")

</div>

> [@JFollo](#):
>
> Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx)

`$regexp('Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx)','(.*?feat.*?) \(feat\.(.*)',$1 &$2)`  
Leads to  
`Mass Of Man - Unhappy (feat. Olivia Charlotte & Bingx)`  
This also works for  
Mass Of Man - Unhappy (feat. Olivia Charlotte (feat. Bingx (feat. Misc)  
in a first step as it leads to  
`Mass Of Man - Unhappy (feat. Olivia Charlotte & Bingx (feat. Misc)`  
so you simply run the action twice.  
To get the first & into a comma:  
`$regexp('Mass Of Man - Unhappy (feat. Olivia Charlotte & Bingx & Misc)','(.*?) & (.*)','$1, $2' )`

Use the scripting commands in an action of the type "Format value" or Convert\>Tag-Tag

---

<div class="post-metadata">

**Author:** ![JFollo](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/j/a9adbd/32.png) [@JFollo](https://community.mp3tag.de/u/JFollo)\
**Post date:** [April 21, 2023, 6:56pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/3 "2023-04-21T18:56:37Z")

</div>

Thank you very much for the quick reply and taking the time to answer my question.

---

<div class="post-metadata">

**Author:** ![JFollo](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/j/a9adbd/32.png) [@JFollo](https://community.mp3tag.de/u/JFollo)\
**Post date:** [April 21, 2023, 7:07pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/4 "2023-04-21T19:07:44Z")

</div>

Well I guess I do have a follow up question.

What if its a different band or text? Is there code to replace the 2nd (feat. "Any band" to a & symbol?  
Generic code for any band?

And the same if there is two extra (feat. 1st (feat. to a comma and 2nd (feat. to a & symbol?  
Generic code for any band or text?

Thanks again

---

<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:** [April 21, 2023, 7:16pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/5 "2023-04-21T19:16:09Z")

</div>

> [@JFollo](#):
>
> Generic code for any band or text?

No, MP3tag cannot read and does not have a word storage to compare that with the text in the fields.

The best way would be to filter for the files that need treatment.

---

<div class="post-metadata">

**Author:** ![JFollo](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/j/a9adbd/32.png) [@JFollo](https://community.mp3tag.de/u/JFollo)\
**Post date:** [April 21, 2023, 7:17pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/6 "2023-04-21T19:17:18Z")

</div>

Thanks again for your response.

---

<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:** [April 21, 2023, 7:18pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/7 "2023-04-21T19:18:27Z")

</div>

You filter e.g with  
`%title% MATCHES "(feat.*feat"`

---

<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:** [May 21, 2023, 7:19pm UTC](https://community.mp3tag.de/t/help-with-duplicate-text/60764/8 "2023-05-21T19:19:20Z")

</div>

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