Making an action on adding featured artist's to a title

So I want to make an action where everything after the first comma in the artist's field gets added to the title field and the last comma gets tuned to a "&"

For example:

Title: Only
Artists: Nicki Minaj, Lil Wayne, Drake, Chris Brown

After the action

Title: Only (feat. Lil Wayne, Drake & Chris Brown)

Try an action of the type "Guess value" (import tag fields)
Source:$regexp('%title%==%artist%','(.*)==(.*?),(.*)',$1 (feat.$3)==$2)
Target format string: %title%==%artist%


It didn't work properly.. did I do something wrong?

In the source, remove the single quotes around %title%==%artist%, like this:
$regexp(%title%==%artist%,'(.*)==(.*?),(.*)',$1 (feat.$3)==$2)

This action works but it removes the names from the artist field.. Like this

Title: Only
Artists: Nicki Minaj, Lil Wayne, Drake, Chris Brown

After the action

Title: Only (feat. Lil Wayne, Drake & Chris Brown)
Artists: Nicki Minaj

And I still want the last comma to be turned to a '&'

Try an action of the type "Format value" for TITLE
Format string: %title% (feat. $regexp($regexp(%artist%,'(.*?), (.*)',$2),'(.*), (.*)',$1 & $2))

1 Like

Thank you so much it worked. Have a blessed day! :grin: :grin:

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