Remove the double indication of an ARTIST in the TITLE

ARTIST versus TITLE doubles

After I have searched the forum about the topic "featuring",
I managed to solve most of my issues.
Currently I would like to solve the following remaining task:
Remove the double indication of an ARTIST in the TITLE.
Dups in just one field are discussed and solved already.
But in this case there are two values to be compared.


ARTIST: Papik; Paco Di Maso
TITLE: Balliamo (Featuring Paco Di Maso)

This scheme also appears without the brackets.
This is to be corrected in:

ARTIST: Papik; Paco Di Maso
TITLE: Balliamo

Does anyone have a suitable idea using $regexp?

I would (as always when there are complicated conditions) first filter for the data.
"$ifgreater($strstr(%title%,$regexp(%artist%,(.*); (.*),$2)),0,yes,no)" IS yes
(which filters whether the second artist is part of the TITLE)
And then remove the bits that describe the featured artist.
You could then check whether there are other featured artists that are not yet part of the artist field and therefore probably should not be removed.

Ohrenkino, as I have experienced several times, you are an expert on regexp.

However, I am not interested in finding the songs in question, but about correcting them. I would like to do this with a script.
This script will probably use a regexp in the core again, but I do not get it at the moment how.

Too much of an honor.
The problem for me is: I don't know how to go through a list of artists and then look for each whether there is a equivalent in the TITLE.
What I do know is how to filter for at least 1 occurrance and then remove a whole part of the TITLE, e.g with
$regexp(%title%,(.*) \(feat.*,$1)
But what about the cases where you have a list of artists like
2pac; Nate Dogg - All About U (featuring Dru Down; Nate Dogg; Snoop Doggy Dogg)

should then the "featuring" part be removed completely or just the artist that happens to be in the field ARTIST as well? (Why, I would ask myself, aren't the other featured artists in the ARTIST field as well - should they be moved there now?)

And what if there are more than just 2 artists in ARTIST - that is where my skills in regular expressions find their limits. I don't know how to do a "for each".

That are exactly the challenges :grimacing: to make this task successful.
The solution will be used once in a week to correct the songs in question.
I'll think about a script that solves this issue.
What about to move all artists to ARTIST and remove duplicates?
But what about "Earth, Wind & Fire" and similars?
Maybe similar to this:
FINDING duplicates

You already have multiple artists in ARTIST.
If you press ALT + T on this track you can see if there are multiple ARTIST tags filled or only one ARTIST tag with multiple names in the same tag.

Multiple ARTIST is okay,
Duplicate ARTIST not.

I know :wink:
There are different ways if you have multiple ARTIST tags or only one.
Could you please check it or show us a screenshot?

This is the discussed item.
(The final script divides ARTIST in multiple entries.)

Here comes another one:

Here is another example, even worse:

See e.g. this thread:

@OHRENKINO: That's exactly the link I referenced in my last answer. :upside_down_face:

I hoped that would work for you:

but in my own tests I couldn't get it working with your example(s).