# Assign number to word?

**URL:** https://community.mp3tag.de/t/assign-number-to-word/15666
**Category:** Support
**Created:** [April 19, 2014, 12:35pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666 "2014-04-19T12:35:44Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![marcusj0015](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/m/43a26b/32.png) [@marcusj0015](https://community.mp3tag.de/u/marcusj0015)
#### Post date: [April 19, 2014, 12:35pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666/1 "2014-04-19T12:35:44Z")

</div>

How can I assign a number to a specific word? for example, I'm trying to display the iTunesAdvisory tag (basically it tells you if a song is the clean version or the explicit version) and the tag is stored with a value of 0 if the tag doesn't exist, 2 if it's clean, and 4 if it's explicit, I want to basically have mp3tag read that tag, and instead of printing a 4, I want it to print "Explicit", how can I do this?

Also, I'm trying to create a custom column in MP3Tag, that will tell me if a song is explicit, clean, or unknown.

---

<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: [April 19, 2014, 2:26pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666/2 "2014-04-19T14:26:41Z")

</div>

You could use the function  
$replace()  
for that display.

E.g. you define a new column and enter as ""value"  
$replace(%advisory%,2,Clean,4,Explicit)  
(%advisory% stands for the real name of the field)

Do not enter anything for "Field" if you want to keep the contents of the original field.

---

<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: [April 19, 2014, 3:17pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666/3 "2014-04-19T15:17:41Z")

</div>

> [@marcusj0015](#):
>
> How can I assign a number to a specific word? for example, I'm trying to display the iTunesAdvisory tag (basically it tells you if a song is the clean version or the explicit version) and the tag is stored with a value of 0 if the tag doesn't exist, 2 if it's clean, and 4 if it's explicit, I want to basically have mp3tag read that tag, and instead of printing a 4, I want it to print "Explicit", how can I do this? ...

See also ...  
[iTunes metadata](https://community.mp3tag.de/t/9596/5)

**$ifgreater(%ITUNESADVISORY%,3,'Explicit',$ifgreater(%ITUNESADVISORY%,1,'Clean','None') $replace(%ITUNESADVISORY%,0,'None',2,'Clean',4,'Explicit')**

**New with Mp3tag v2.59**

**$ifgreater(%ITUNESADVISORY%,1,'Clean',$ifgreater(%ITUNESADVISORY%,0,'Explicit','None') $replace(%ITUNESADVISORY%,0,'None',1,'Explicit',2,'Clean')**

See also ...  
[https://docs.mp3tag.de/mapping/#tag-fields-exclusive-to-mp4](https://docs.mp3tag.de/mapping/#tag-fields-exclusive-to-mp4)

DD.20140419.1918.CEST, DD.20140420.2037.CEST

---

<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: [April 19, 2014, 3:19pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666/4 "2014-04-19T15:19:43Z")

</div>

The field's name is ITUNESADVISORY in Mp3tag. I've also noticed that recent versions of iTunes also use 1 for marking explicit content.

So to define the column ohrenkino is referring to, you could use  
$replace(%itunesadvisory%,0,None,1,Explicit,2,Clean,4,Explicit)

---

<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:25pm UTC](https://community.mp3tag.de/t/assign-number-to-word/15666/5 "2026-02-09T12:25:00Z")

</div>


