Author Topic: regular expressions in Music Bee  (Read 1332 times)

pmorrison

  • Newbie
  • *
  • Posts: 6
I need help with regular expressions.

I want to modify the COMPOSER tag throughout my collection so it reads (LASTNAME, FIRSTNAME, MIDDLENAME), to retain all diacritical characters, and to break the "middlename" at the first name (Ludwig von Beethoven = Beethoven, Ludwig von

I want to use the search and replace feature in Music Bee to do this via regular expressions.  I have the match string:

^([\p{L}.-]*) ?([\p{L},.'-]*) ([\p{L} ,.'-]*)

but my replacement string
\3, \1 \2

does not work.  I get \3, \1 \2 for the name, where 3 should produce = Beethoven, etc.

What am I doing wrong?


The Incredible Boom Boom

  • Sr. Member
  • ****
  • Posts: 1419
You want to use $# instead of \# in the "replace with" part.

(.+)\s(.+)$ and $2, $1 are a bit easier, though.