# Appending to title field

**URL:** <https://community.mp3tag.de/t/appending-to-title-field/59181>\
**Category:** Support\
**Created:** [November 24, 2022, 8:59pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181 "2022-11-24T20:59:46Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![lordlance](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/51bf81/32.png) [@lordlance](https://community.mp3tag.de/u/lordlance)\
**Post date:** [November 24, 2022, 8:59pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/1 "2022-11-24T20:59:46Z")

</div>

I wanted to add '(Complete Show)' to a bunch of my tracks so I used quick regex, selected title and:  
Match: (.\*)  
Replace: \1 (Complete Show)

I always get 2 complete shows for some reason:

 ![image](https://community.mp3tag.de/uploads/default/original/2X/f/f70843441c77c8792cf1c3ea24c3f3be64c6ec9c.png)  
 ![image](https://community.mp3tag.de/uploads/default/original/2X/b/b2f0a6a285ed27eb7fc7f9dd04f82161a52a4fee.png)

What's going on?

---

<div class="post-metadata">

**Author:** ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)\
**Post date:** [November 24, 2022, 9:16pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/2 "2022-11-24T21:16:12Z")

</div>

`(.*)` also matches the empty string, try `(.+)` instead.

---

<div class="post-metadata">

**Author:** ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)\
**Post date:** [November 24, 2022, 10:11pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/3 "2022-11-24T22:11:02Z")

</div>

An alternative would be to use Convert\>Tag-Tag for TITLE  
Format string: %title% (Complete Show)

---

<div class="post-metadata">

**Author:** ![lordlance](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/51bf81/32.png) [@lordlance](https://community.mp3tag.de/u/lordlance)\
**Post date:** [November 28, 2022, 3:56am UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/4 "2022-11-28T03:56:00Z")

</div>

What do you mean by matching an "empty string"? The whitespace? Some titles have more than one space character.

.+ does not work. The title remains unchanged.

---

<div class="post-metadata">

**Author:** ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)\
**Post date:** [November 28, 2022, 6:33am UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/5 "2022-11-28T06:33:57Z")

</div>

Then please show us the regular expression in a screendump.

I just tried this:  
 ![grafik](https://community.mp3tag.de/uploads/default/original/2X/a/a34c5300bdc92148adbee6ae806082611faea7aa.png)  
which looks ok  
whereas  
 ![grafik](https://community.mp3tag.de/uploads/default/original/2X/4/4f0da55002def364809c75b5aa50c10807b2ee22.png)  
does not.

---

<div class="post-metadata">

**Author:** ![lordlance](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/51bf81/32.png) [@lordlance](https://community.mp3tag.de/u/lordlance)\
**Post date:** [November 28, 2022, 7:27pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/6 "2022-11-28T19:27:51Z")

</div>

Huh it worked today. Can someone explain why .\* causes problems but .+ does not? Furthermore why does the appended word repeat twice regardless of how many words are in the original title.

---

<div class="post-metadata">

**Author:** ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)\
**Post date:** [November 28, 2022, 7:44pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/7 "2022-11-28T19:44:28Z")

</div>

> [@Florian](#):
>
> `(.*)` also matches the empty string, try `(.+)` instead.

I think this is the explanation. The `*` matches the previous token `.` (any character) between zero and unlimited times, as many times as possible. So it also matches zero times (in addition to one time) and produces an output for this case.

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [December 28, 2022, 7:45pm UTC](https://community.mp3tag.de/t/appending-to-title-field/59181/8 "2022-12-28T19:45:15Z")

</div>

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