# delete trailing characters from tag (regex help)

**URL:** https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643
**Category:** Support
**Created:** [October 26, 2007, 12:34pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643 "2007-10-26T12:34:25Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![digraph](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/eb8c5e/32.png) [@digraph](https://community.mp3tag.de/u/digraph)
#### Post date: [October 26, 2007, 12:34pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643/1 "2007-10-26T12:34:25Z")

</div>

I know this is super simple for most of you, but I'm having trouble.

My BPM tags are written in xxx.xx format, with two decimal place precision.  
However, itunes mac chokes on this (windows does not, go figure).

Anyway, since all BPM data is either: xx.xx or xxx.xx I'd like to simple remove the last three characters.

Simple, huh?

Extra points for rounding the integer part up or down.

thanks!!

---

<div class="post-metadata">

### Author: ![digraph](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/eb8c5e/32.png) [@digraph](https://community.mp3tag.de/u/digraph)
#### Post date: [October 26, 2007, 12:56pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643/2 "2007-10-26T12:56:58Z")

</div>

How about that, I solved my own question

you match it with this:

.[0-9]+

anyway, thanks for the great program!

---

<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: [October 26, 2007, 1:09pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643/3 "2007-10-26T13:09:47Z")

</div>

> [@digraph](#):
>
> ... My BPM tags are written in xxx.xx format, with two decimal place precision. ... I'd like to simple remove the last three characters. ... Extra points for rounding the integer part up or down. thanks!!

First look here:  
[BPM-Nachkommastellen runden ... ?](https://community.mp3tag.de/t/4290/1)

Round BPM to integer.mta

Action #1:  
_Action type:_ **Format value**  
_Field:_ **BPM\_MIXMEISTER**  
_Formatstring:_ **$if2(%BPM\_MIXMEISTER%,%BPM%)**

Action #2:  
_Action type:_ **Format value**  
_Field:_ **BPM**  
_Formatstring:_ **$left($replace(%BPM%,.,)00,$add($len($div(%BPM%,1)),2))**

Action #3:  
_Action type:_ **Format value**  
_Field:_ **BPM**  
_Formatstring:_ **$ifgreater($mod(%BPM%,100),44,$add($div(%BPM%,100),1),$div(%BPM%,100))**

DD.20071026.1710.CEST

---

<div class="post-metadata">

### Author: ![digraph](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/eb8c5e/32.png) [@digraph](https://community.mp3tag.de/u/digraph)
#### Post date: [October 26, 2007, 2:51pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643/4 "2007-10-26T14:51:06Z")

</div>

This is excellent! Thank you for the help 🙂

---

<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: [February 9, 2026, 12:20pm UTC](https://community.mp3tag.de/t/delete-trailing-characters-from-tag-regex-help/5643/5 "2026-02-09T12:20:33Z")

</div>


