# Trying to add sequential numerical prefix to Title

**URL:** <https://community.mp3tag.de/t/trying-to-add-sequential-numerical-prefix-to-title/57614>\
**Category:** Support\
**Created:** [June 12, 2022, 9:48pm UTC](https://community.mp3tag.de/t/trying-to-add-sequential-numerical-prefix-to-title/57614 "2022-06-12T21:48:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![MotorCentaur](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/m/b782af/32.png) [@MotorCentaur](https://community.mp3tag.de/u/MotorCentaur)\
**Post date:** [June 12, 2022, 9:48pm UTC](https://community.mp3tag.de/t/trying-to-add-sequential-numerical-prefix-to-title/57614/1 "2022-06-12T21:48:10Z")

</div>

Hi,  
My first post. I am not a coder by any means...

I just bought a newer Subaru, the media player sorts the album tracks alphabetically by title, which is highly annoying. I like to maintain the order they were on the albums.

I am trying to bulk rename the titles tag to retain the title, but put a sequential 2 (or occasionally 3) digit number in front of the existing title. ie; 01 First Song, 02 Second Song, 03 Third Song.

I have replacing values with actions and convert Tag\>Tag, with "$num(01,2) %title%" -which will preserve the title but doesn't count up, just puts a 01 prefix in front of everything.

I tried the add function but didn't get anywhere. Other things I've tried just remove the title completely. I haven't been able to get anything to count up by 1 each line.

If someone could give me a working example of that would work I would greatly appreciate it.

thanks in advance,  
R

---

<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:** [June 13, 2022, 5:21am UTC](https://community.mp3tag.de/t/trying-to-add-sequential-numerical-prefix-to-title/57614/2 "2022-06-13T05:21:27Z")

</div>

> [@MotorCentaur](#):
>
> I have replacing values with actions and convert Tag\>Tag, with "$num(01,2) %title%" -which will preserve the title but doesn't count up, just puts a 01 prefix in front of everything.

That was close!  
To assign something new to a field try an action of the type "Format value" (here: for TITLE) or use Converter\>Tag-Tag.  
Format string: `$num(%_counter%,2)_%title%`

See the documentation on scripting

> **[Scripting Functions – Mp3tag Documentation](https://docs.mp3tag.de/scripting/)**
>
> Documentation on Mp3tag's scripting functions. Mp3tag is the universal Tag Editor.

and variables

> **[Format Strings and Placeholders – Mp3tag Documentation](https://docs.mp3tag.de/format/)**
>
> Documentation on format strings and placeholders to describe the structure of file names and imported data. Mp3tag is the universal Tag Editor.

---

<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:** [July 13, 2022, 5:21am UTC](https://community.mp3tag.de/t/trying-to-add-sequential-numerical-prefix-to-title/57614/3 "2022-07-13T05:21:43Z")

</div>

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