(14-02-2014 15:27)simoncn Wrote: [ -> ]... that doesn't solve the OP's problem of how to get his artist names into the "lastname, firstname" format.
I seem to recall that we have discussed using the ArtistSort tag on the forum. This could be used now (I use ComposerSort, but not, as yet, ArtistSort). My problem was to create correctly populated ComposerSort tags in hundreds of albums that did not have them; a requirement to create ArtistSort tags (or to write all the Artist entries in sort order) would be logically similar.
Apart from a bit of head scratching over syntax, the problem was remarkably easy to solve using Actions in MP3Tag. In my "Reverse Names in ComposerSort - 1 last name" action, I use the following regular expression:
$regexp(%COMPOSER%,(.*) (.*),$2',' $1)
This splits the contents of the Composer tag into two sections (or "sets"), the divider being the final space (that's the "(.*) (.*)" bit, meaning "any number of characters, then a final space, then any number of characters"). It then reverses the two sets, placing ", " between them. This works for "Ludwig van Beethoven" (Beethoven, Ludwig van) but not for "Ralph Vaughan Williams" (Williams, Ralph Vaughan). So I also have a "Reverse names in ComposerSort - 1 first name" action, where the regular expression is:
$regexp(%COMPOSER%,(.*?) (.*),$2',' $1)
This expression is exactly like the other, except for the insertion of the question mark in the definition of the first set. This makes the set "non greedy", so the split is at the first space, not the last, and gives "Vaughan Williams, Ralph" in ComposerSort. (I haven't yet come across a composer with both more than one customarily used first name and more than one unhyphenated surname. If I do, I shall probably enter that name manually!) An action such as this can be applied in MP3Tag to any number of files at once.
The point of all this geekiness is to show that batch updating of metadata can be remarkably quick. Even being careful and taking only one composer at a time, I was able to create ComposerSort Tags in several thousand tracks in less than an hour.
I use ComposerSort, and am likely to continue doing so, because I want to sort by last name but display the names in first name - last name format. ComposerSort goes into indexTags and Composer goes into itemTags. In tagFormat, I have an entry "ComposerSort.displayFormat={$composer}". Again, I think that it would be straightforward to apply this approach to the Artist and ArtistSort tags.
All of this works for me, but I am less sure that it meets the needs of others. If it does, is it worth my trying to put together a step by step tutorial? It could save someone else all the head banging that those infernal regular expressions cost me ...
David