Action #1
Actiontype 7: Import tag fields (guess values)
Source format: %FILENAME%
Guessing pattern: %P1%%P2%%P3%%P4%_%P5%
Action #2
Actiontype 5: Format value
Field: P5
Formatstring: $caps2(%P5%)
Action #3
Actiontype 5: Format value
Field: P5
Formatstring: $regexp(%P5%,'(?<!^)(\u\l|(?<=\l)[\u\d])',' $1')
Action #4
Actiontype 5: Format value
Field: P0
Formatstring: %P5%÷-÷%P2%-%P3%
Action #5
Actiontype 5: Format value
Field: _FILENAME
Formatstring: %P0%
Action #6
Actiontype 9: Remove fields
Fields to remove (semicolon separated): P0;P1;P2;P3;P4;P5
Note: Replace each special ÷ character with one space character.
End Action Group Test_2011#20110606.Thorrrr (6 Actions)
From:
5871_01_01_SC11_learningWeb
5871_01_02_SC11_whatisDW
5871_01_03_SC11_CSSRules
To:
Learning Web - 01-01
Whatis DW - 01-02
CSS Rules - 01-03
DD.20110606.1243.CEST
============================================================
Addendum-1
If someone does not need to split the 'camel cased' textual part and does not need to delimit the words by a space character, then the formatting action using the $regexp expression can be removed.
The formatting action for tag-field 'P0' can be removed too.
Also the upcasing can be taken into the formatting action.
Also %P1% and %P4% can be replaced by %DUMMY%.
So the reduced action group will look like the following ...
Action #1
Actiontype 7: Import tag fields (guess values)
Source format: %FILENAME%
Guessing pattern: %DUMMY%%P2%%P3%%DUMMY%_%P5%
Action #2
Actiontype 5: Format value
Field: _FILENAME
Formatstring: $caps2(%P5%)÷-÷%P2%-%P3%
Action #3
Actiontype 9: Remove fields
Fields to remove (semicolon separated): P2;P3;P5
Note: Replace each special ÷ character with one space character.
End Action Group Test_2011#20110606.Thorrr.2 (3 Actions)
From:
5871_01_01_SC11_learningWeb
5871_01_02_SC11_whatisDW
5871_01_03_SC11_CSSRules
To:
LearningWeb - 01-01
WhatisDW - 01-02
CSSRules - 01-03
============================================================
Addendum-2
The reduced problem as described in Addendum-1 can also be solved by the converter "Filename - Filename".
Convert | Filename - Filename | ALT+3
Select format string
Old filename pattern:
%1_%2_%3_%4_%5
New filename pattern:
$caps2(%5) - %2-%3
Preview
LearningWeb - 01-01.mp3
============================================================
Addendum-3
The complete problem including 'camel case splitting' can also be solved by the converter "Filename - Filename".
Convert | Filename - Filename | ALT+3
Select format string
Old filename pattern:
%1_%2_%3_%4_%5
New filename pattern:
$regexp($caps2(%5),'(?<!^)(\u\l|(?<=\l)[\u\d])',' $1') - %2-%3
Preview
Learning Web - 01-01.mp3
============================================================
Note:
Due to the converter "Filename - Filename" Mp3tag does not need to work physically on tag-fields within the files.
This might drastically reduce the processing time to a minimum.
Especially when processing large files such as MP4 files.
DD.20110606.1906.CEST