How to remove featured artist from Album Artist

I read through similar threads on this and couldn't get a working solution. This solution should be exactly what I want if I just modify it to work with Album Artist instead, but I can't get it to work as it is (applying to Artist field).

What I tried
Action: Format tag field
Field: ARTIST
Format: $regexp(%ARTIST%,'^(.+?)\s+[[({]?(?:ft\.?|feat\.?|featuring)\s+(?:[^][(){}]+)[])}]?(\s*.+)?$','$1$2',1)

Undesired result
Artist field: Invalid regular expression: ^(.+?)\s+[[({]?(?:ft\.?|feat\.?|featuring)\s+(?:[^][(){}]+)[])}]?(\s*.+)?$

What I want
If I can get this to work, I suspect I can modify it by swapping out ARTIST to ALBUMARTIST to work in Album Artist field, which is what I actually want.

EXAMPLE:

Source
Album Artist: Dr. Dre (Ft. Devin the Dude & Snoop Dogg)

Desired result
Album Artist: Dr. Dre

Any help is appreciated.

Without trying it out myself, I think the regular expression is missing two backslashes in front of closing square brackets ]. Try this one:

$regexp(%ARTIST%,'^(.+?)\s+[[({]?(?:ft\.?|feat\.?|featuring)\s+(?:[^\][(){}]+)[\])}]?(\s*.+)?$','$1$2',1)

I would be rather reluctant to use regular expressions that I cannot maintain.
So why not try something simpler? Like an expression that deletes everything inside round brackets?
$regexp(%albumartist%,(.*) \(.*,$1)
And to make sure that "Was (not was)" does not get caught, I would filter for
%albumartist% HAS (f

Unfortunately, that still results in "invalid regular expression" like before, but I do appreciate the help. I think I will just settle for ohrenkino's suggestion below.

Probably smart advice indeed.

I have carefully created an action group with ~100 different actions that can be run all at once. My goal is to be able to take music from various sources and in one click have it all formatted/tagged exactly how I want. I understand this would never bee 100% perfect, but it could be very close, saving me a bunch of time.

Basically, I'm trying to minimize the steps I'd need to take every time I'm organizing a new batch of music. Your suggestion of filtering "(f" and removing everything inside the round brackets is a good one, just not quite as streamlined as I was hoping.

The purpose of removing the featured artist from Album Artist, is because one of the actions in my group is to copy the Artist to Album Artist IF Album Artist is empty, so in some cases that would result in a featured artist being in Album Artist. Obviously this won't always give me the ideal end result, but it could minimize the amount of manual corrections I'd have to perform.

Thanks again for your help!

see this post about removing the featured artist:

Still, if you really let loose

then you would have to understand thoroughly what each action does to either debug them or modify them if the result in the end is not what you expected.

Just another aspect: filtering reduces the number of files to those that really should be treated. So, the total processing time will be shorter and you can be sure that your actions do not lead to unwanted side effects in files that already have been treated (successfully).
And if you use a backup program then that will backup fewer files which is usually faster.

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