If you select the Genre field it will replace "[Rock, Heavy Metal, Thrash Metal]" with "[R,HM,TM]"
It will not change Rock to R as it looks for the 'replace' string as a unit. You have to do this with multiple replace statements. Further as there can be lots of Rock genres you should do it as a list. If your genres are delimited by commas, you could do it as follows:
1: Replace "Rock", case insensitive in the Genre field, as list with delimiter "," with "R"
2: Replace "Heavy Metal", case insensitive in the Genre field, as list with delimiter "," with "HM"
3: Replace "Thrash Metal", case insensitive in the Genre field, as list with delimiter "," with "TM"
4: Trim the Genre field, as list with delimiter "," (SP) [Leading] [Trailing]
The 'Trim' statement is only required if you want to remove spaces before and after each genre.
There is an easier way to do this if you have a lot of genres to replace. Make a Replacement Set named Genre Replacements. (see attached image) and use the following:
1: Set Default Replacement set to (Genre Replacements)
2: Case No Change in the Genre field with replacements, process as list with delimiter ","
3: Set Default Replacement set to (pre-action value)
4: Trim the Genre field, as list with delimiter "," (SP) [Leading] [Trailing]
Statement 1 changes the default replacement set to be Genre Replacements. Statement 2 uses the Case statement with no case transformations but applies replacements ... again as a list. Statement 3 resets the default default replacement set. Statement 4 is the same Trim as before. Statements 1 and 3 are a Preferences statement Statement 2 is a Case. Statement 4 is a Trim statement
|