# writing file creation date to tag with this format : YYYYMMDD (year, month, day)

**URL:** https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174
**Category:** Support
**Created:** [November 23, 2010, 4:58pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174 "2010-11-23T16:58:37Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![abducted](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@abducted](https://community.mp3tag.de/u/abducted)
#### Post date: [November 23, 2010, 4:58pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/1 "2010-11-23T16:58:37Z")

</div>

Hi, I would like to write the file creation date into the "year" tag.  
In fact I know how to do it with "actions" but it is writing it in this format : DD/MM/YYYY  
and I prefer this format : YYYYMMDD. SO how to change the date format and write it into  
a tag please?

---

<div class="post-metadata">

### Author: ![pone](https://community.mp3tag.de/user_avatar/community.mp3tag.de/pone/32/272_2.png) [@pone](https://community.mp3tag.de/u/pone)
#### Post date: [November 23, 2010, 5:16pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/2 "2010-11-23T17:16:24Z")

</div>

~~**%\_file\_create\_date%** gives you DD.MM.YYYY not DD/MM/YYYY~~

**$regexp(%\_file\_create\_date%,(..)/(..)/(....),$3$2$1)** gives you YYYYMMDD like you want it.

Edit:  
How to write it into a tag:  
Action: Format Value  
Field: YEAR  
Format String: $regexp(%\_file\_create\_date%,(..)/(..)/(....),$3$2$1)

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [November 23, 2010, 5:24pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/3 "2010-11-23T17:24:03Z")

</div>

The format that %\_file\_create\_date% returns depends on your region settings in windows.  
So it is possible that it returns DD/MM/YYYY

'. does not escape . You need .

---

<div class="post-metadata">

### Author: ![abducted](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@abducted](https://community.mp3tag.de/u/abducted)
#### Post date: [November 23, 2010, 5:31pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/4 "2010-11-23T17:31:48Z")

</div>

I tried and it works ! Thanks (and yes my date format is really DD/MM/YYYY because I'm in France)

And by the way....How to trim the last character of a tag please ? That's because I have some  
old files tagged like this : "YYYYMMDD1" and I'd like to delete the "1" from the tag to make it simply "YYYYMMDD". (Of course I could do it manually but I want to create an action for it because there are  
many files to process)

---

<div class="post-metadata">

### Author: ![pone](https://community.mp3tag.de/user_avatar/community.mp3tag.de/pone/32/272_2.png) [@pone](https://community.mp3tag.de/u/pone)
#### Post date: [November 23, 2010, 5:35pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/5 "2010-11-23T17:35:39Z")

</div>

> [@dano](#):
>
> The format that %\_file\_create\_date% returns depends on your region settings in windows.  
> So it is possible that it returns DD/MM/YYYY

thank you dano, i edited my post.

> [@](#):
>
> '. does not escape . You need .

actually both work, at least at format value.  
(thinking about it, maybe not. if **.** is not escaped it can be represented by any character including **.** )

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [November 23, 2010, 10:59pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/6 "2010-11-23T22:59:47Z")

</div>

@abducted  
_$left(%year%,8)_  
gives you the first 8 characters

---

<div class="post-metadata">

### Author: ![abducted](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/b9bd4f/32.png) [@abducted](https://community.mp3tag.de/u/abducted)
#### Post date: [November 24, 2010, 8:19am UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/7 "2010-11-24T08:19:04Z")

</div>

Thanks Dano !

---

<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:22pm UTC](https://community.mp3tag.de/t/writing-file-creation-date-to-tag-with-this-format-yyyymmdd-year-month-day/11174/8 "2026-02-09T12:22:42Z")

</div>


