Hello guys.
My goal this time is to create an action set that will turn [The Beatles, Billy Preston] into [Beatles, Billy Preston, The] using regular expression. I have referred the previous post and his method doesn't cover mine. Unfortunately, I'm not yet adept on using the format string method therefore am once again requiring your support.
To be honest: do you really have to move the "The" to the end? If the new string is used for sorting, then I bet it would be enough to simply delete the "The".
In respect to the regular expression:
Search string: The (.*)
Replace string: $1, The
I am not angry or so , no, really not.
I just sometimes wonder why things should be so overcomplicated.
To get rid of the leading "The", you could try:
An Action of the type "Replace with regular expression" for ARTISTSORT
Search string: ^The_
(The _ = space)
Replace string:
(leave empty)
No I haven't. In my understanding, your solution only applies if we're dealing with The Beatles only, or something similar. Does it work with a second artist in the field together? Excuse me if I'm slow in following I'm learning this bit by bit and just prodding and trying things.
Well, if you have not tried them why am I bothering?
I don't read anything about the Beatles in my suggestion just the pattern of a string which starts with "The" and that "The" is moved to the end or gets deleted.
That works for every string with that pattern, regardless how many words, commas, hyphens, you name it, are following the "The".
It works here.
Is it really the field ARTISTSORT you are treating or is it the field ARTIST?
What is the present content of ARTISTSORT?
If you have only filled ARTIST and want to move the content from ARTIST without "The" to the field ARTISTSORT take the converter Tag->Tag:
Field: ARTISTSORT
Formatstring: $regexp(%artist%,^The ,)