# Some regexp issues

**URL:** https://community.mp3tag.de/t/some-regexp-issues/9546
**Category:** Support
**Created:** [December 16, 2009, 8:14pm UTC](https://community.mp3tag.de/t/some-regexp-issues/9546 "2009-12-16T20:14:40Z")
**Posts on this page:** 1
**Showing post:** 6

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [December 22, 2009, 5:46pm UTC](https://community.mp3tag.de/t/some-regexp-issues/9546/6 "2009-12-22T17:46:06Z")

</div>

> [@pmj1989](#):
>
> Well. I am familiar with those actions/scripting functions which are covered by the official manual and therefore I don't understand some parts of your tip. ...

Hmm, the world is bigger than the Mp3tag manual can describe.

> [@pmj1989](#):
>
> ...So here are questions to let you guide me:
> 
> 1. Is it written to use with "Format value" or with "Replace with regular expression"? I guess, with the first one. Am I right? ...

Because I titled my answer with "Example", it should be an example, not a ready made solution.  
Somewhat in the same manner, as your first given example.  
My example mainly can be read as a $regexp() scripting function, which can be used e. g. within an action "Format value".  
On the other hand, with little modifications, just extract the regular expression and the replacement, you might be able to use it within an action "Replace using Regular Expression".

> [@pmj1989](#):
>
> ... 2. This is how I understand the idea of $regexp() function (divided to make it clear) ... Why every part of a function is between -\> ' ' (?!) And btw... Why mp3tag sometimes want us to use "/" and sometimes -\> ' ' to output raw text? ...

I often use the 'apostrophe clamp' to make clear that this entire function's parameter is a literal, it can make some expressions to be read easier for the user.

> [@pmj1989](#):
>
> ...  
> PART 1:  
> If it is thus it must be valid for EVERY %title%. Not just particular one, right? I wouldn't make function just to edit single song! The number of featured artist also varies (I mentioned 3 as an example), naturally sometimes there are no featured artists at all.
> 
> PART 2:  
> The thing is I don't understand it. Manual doesn't explain non-literals like "^", "s", "$"... No idea what's going on in this part!
> 
> PART 3:  
> I bet it gets clear after I understand PART 2...
> 
> Please answer in plain English. I'm not a native speaker as you might noticed ![:rolleyes:](https://community.mp3tag.de/uploads/default/original/1X/3a79e8b0b7d169b30216785521d7c6f4f895c421.gif ":rolleyes:")

Hmm, Mp3tag is an application, which makes use of different standard software techniques, e. g. window views, user dialogs, mouse handling, list view, buttons, ID3 tagging, user scriptable programming, filter concept, regular expression and much more we cannot see behind the surface.

Because the Windows user interface has become a standard usability technique, which might not be described and explained in the Mp3tag manual, so it is with Regular Expressions too.

There are some links about using of regular expressions in general:  
[Artist sortieren mit "The"](https://community.mp3tag.de/t/9347/6)  
Study carefully.

As I understand your words and problem analysis, I think you are on a good way to become a thoughtful planning tagger. You have understood that some tag fields may have diffferent content and different formats, therefore the one for all solution cannot be achieved by a simple inquiry here on the board, it may need several concepts to handle your music collection in part of some.

DD.20091222.1946.CET

---

_[View the full topic](https://community.mp3tag.de/t/some-regexp-issues/9546)._
