Renaming Script issue with untagged various artists compilation

Hi

I am renaming all my music files to work better with Plex using Musicbrainz Picard. I have several compilations that are not on the MusicBrainz database. The main problem has been renaming files from compilations for Plex. I have a script below which follows the basic scheme: Album artist/album [year]/album artist - album - trackno - trackartist - tracktitle:

$if2(%albumartist%,%artist%)/

$if(%albumartist%,%album% [%originalyear%]/,) %%

%albumartist% - %album% -

$if($gt(%totaldiscs%,1),%discnumber%-,)

$if($and(%albumartist%,%tracknumber%),$num(%tracknumber%,2) ,)-

$if(%_multiartist%,%artist% - ,)

%title%

This works well in titles that are found in Musicbrainz; however in the ones not on Musicbrainz, I am manually adding the album artist “Various Artists”. The problem is that the script is not including the track artist when renaming. Could someone please take a look at the script to see where I’m going wrong?
I looked for a _multiartist tag that I could set with no luck. Also setting compilation tag also didn’t help.
Thanks

1 Like

If you’re not getting the metadata from MusicBrainz for these albums, where is it coming from? Is the metadata in existing tags in the files or are you parsing it from the file names? In any event, you should be able to see the values that will be used in the tag viewer pane.

I’m guessing that the problem is that there is no %_multiartist% variable set, causing the %artist% portion to not be written. You could do something such as creating a tagging script like:

$set(_multiartist,1)

and leave it disabled. Then run it manually using the right-click context menu on any clusters (albums) that you don’t look up in MusicBrainz. That should force it to include the %artist% portion.

Another alternative (and my preferred recommendation) is to change that line in your file naming script to add a second trigger, like:

$if($or(%_multiartist%,$eq(%albumartist%,Various Artists)),%artist% - ,)

which should automatically include the %artist% portion if the %_multiartist% variable is set or if the %albumartist% tag is “Various Artists”.

1 Like

Hi
Thanks! It works (your preferred recommendation)!.
Yes some releases come with tags already.

Cheers

1 Like

It would be awesome if you could consider adding these releases to the database!

It may take only as it takes you to make manual fixes to your files anyway. Particularly if there’s an importer for the release source. And then your work lives on forever :grin:

No biggie if not, but if you ever feel keen and want a hand let us know here

I use Plex as well, and I should point out that the naming scheme you’re following:

Album artist/album [year]/album artist - album - trackno - trackartist - tracktitle

isn’t the recommended pattern for music. (See the last section on that page for “Various Artist” albums)

The recommended pattern is
AlbumArtist/AlbumName/TrackNumber - TrackName.ext

If the embedded tags in your music are in very good shape, and you’ve configured Plex to prefer embedded tags, the file naming isn’t nearly as important to Plex as it once was, but if you’re not depending on embedded tags, this pattern is safer.

But only if they are actual releases and not a random collection of tracks compiled at home. I wasn’t sure from the initial question which is why I didn’t suggest this.

1 Like