IPB

Welcome Guest ( Log In | Register )

> Notice!

Please take a minute to check our Frequently Asked Questions. Use Search to reveal possible related topics.

Also make sure you've read the Forum Guidelines before posting in this forum.

 
Reply to this topicStart new topic
> If %directory% < 4 letters use %parent_directory%+%directory% ?, (for use with AlbumArtist field)
Da_maniaC
post Jan 31 2012, 19:56
Post #1


Member


Group: Full Members
Posts: 20
Joined: 18-August 07
Member No.: 5470
Mp3tag Version: 2,39



Hi all,

I was wondering if it would be possible to create an action to automatically fill all my "ArtistAlbum" fields with the Album name (which is always located in the directory name)?

Unless: the directory name is 4 letters long or less, the parent directory should be used.
(4 letters or less, means: CD2, CD01, etc).

Any ideas? smile.gif

This post has been edited by Da_maniaC: Jan 31 2012, 20:04
Go to the top of the page
 
+Quote Post
JJ Johnson
post Jan 31 2012, 20:04
Post #2


Member


Group: Full Members
Posts: 890
Joined: 18-April 05
Member No.: 1742
Mp3tag Version: 2.65



This can be done, but....

Don't you have (or want) the album name to be in the ALBUM field? Or do you use ARTISTALBUM instead of ALBUM?

You say the album name is "in" the directory name. All by itself, or does it need to be pulled out of the directory name?

It would be better to identify those disc subdirectories by a naming pattern and use a regular expression instead of just using the name length. You probably have many album names with fewer than five characters, so you could create an action that would be more thorough by using a regex.
Go to the top of the page
 
+Quote Post
Da_maniaC
post Jan 31 2012, 20:37
Post #3


Member


Group: Full Members
Posts: 20
Joined: 18-August 07
Member No.: 5470
Mp3tag Version: 2,39



Hey there,

Thanks for your swift reply!

1.) I do indeed think RegEx probably has the right solution...the thing is that i am not very familiar with it (i only know very basic expressions).

2.) I am using a piece of software (Zune) that needs the "AlbumArtist" field to be filled with information too.
All of my other tag fields are nicely organised, but the "album" field only rarely contains the artist name as well. smile.gif

3.) If it would be possible to extract the Artist name from the directory name (for ex.: the words before the "-" (dash) in the directory name) that would be a fairly good solution. But; this would mean that all albums containing "Various Artists" get consolidated into one view with the software i am using (Zune).

This post has been edited by Da_maniaC: Jan 31 2012, 20:38
Go to the top of the page
 
+Quote Post
JJ Johnson
post Jan 31 2012, 22:05
Post #4


Member


Group: Full Members
Posts: 890
Joined: 18-April 05
Member No.: 1742
Mp3tag Version: 2.65



Ok... ALBUMARTIST, not ARTISTALBUM. For simplicity, I'd do this with a small action group containing three actions:

1.
Action type: Format value
Field: ALBUMARTIST
Format string: %_directory%

2.
Action type: Format value
Field: ALBUMARTIST
Format string: $regexp(%albumartist%,'^cd\s*\d{1,2}$',%_parent_directory%,1)

3.
Action type: Format value
Field: ALBUMARTIST
Format string: $regexp(%albumartist%,'^(.*)-.*$',$trim($1),1)

The first action copies the directory name into ALBUMARTIST. The second will replace that with the parent directory only if the name matches the subdirectory naming pattern ('cd1', 'CD 2', 'cD03', etc.) The third action removes anything after the first dash, leaving only the artist name.

Watch out for any artist names containing dashes. What will happen is that only the first part of the name will end up in the ALBUMARTIST field. You probably don't have very many of these, so you go back and do them manually.

For the 'Various Artists - Album Name' albums I would think you *do* wan't 'Various Artists' for the albumartist name. This puts all of your compilation albums in one place, otherwise you'll end up with album names in your albumartist list instead of only artist names. One thing I like to do with 'Various Artists' albums to use an ALBUMARTIST name of '! Various Artists', which forces this artist name to the beginning of the list when sorted alphabetically.
Go to the top of the page
 
+Quote Post
Da_maniaC
post Feb 1 2012, 19:26
Post #5


Member


Group: Full Members
Posts: 20
Joined: 18-August 07
Member No.: 5470
Mp3tag Version: 2,39



This did the trick perfectly! Thanks a million! smile.gif
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 25th October 2014 - 19:58