Place last two characters of Album in braces

Hi,

I have some releases which have EP as the last two characters, eg. All Cried Out EP.
I would like to place the EP in braces, eg. All Cried Out {EP}.

I have tried the following:
Source format: %album%
Guessing pattern: %album% $right(%releasetype%,2)

Field: ALBUM
Format string: %album% {%releasetype%}

Which results in the following:
All Cried Out EP {}

Try an action of the type "Replace" for ALBUM
Search string: EP
Replace string: {EP}

It may be safer to activate the "Match word" option.

1 Like

Thanks for that! So much simpler.

Your format string
%album% $right(%releasetype%,2)
would replace the existing content in %ALBUM% with the content from %ALBUM% and then add the right 2 characters from %RELEASETYPE%. In the second example you put it in {}. It seems, that your content in %RELEASETYPE% is empty or at least the 2 right characters in %RELEASETYPE% are empty.
This result in
All Cried Out EP {}

Please be aware, that replacing EP with {EP} will replace every occurence of EP, also in this example
This is EP number 1
into
This is {EP} number 1
not only if EP was found as last two characters in %ALBUM%.

To replace the last two characters in the content of album with curly braces (if this characters are EP), you could use this regular expression:
$regexp(%ALBUM%,\s(EP)$, {$1})
This searches for a space EP at the end and replace it with a space an opening curly bracket, followed by EP and a closing curly bracket.

1 Like

Or a filter like
%album% HAS " EP"
may lead to a lot of hits.
At least I did not have an album where a word starts with "EP"

There could be some additional infos (at least in my collection) like
"Microfunk EP, Volume 2"
or
"Rare EP Tracks 1961-1966"
or
"The Singles, The EP and The Demos"
or
"The EP Collection"
or
"EP 2010"

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