# \[X\] Single quote in export filename causes error

**URL:** https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632
**Category:** No Bugs
**Created:** [January 4, 2010, 12:11am UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632 "2010-01-04T00:11:54Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![chrisjj](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/a698b9/32.png) [@chrisjj](https://community.mp3tag.de/u/chrisjj)
#### Post date: [January 4, 2010, 12:11am UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/1 "2010-01-04T00:11:54Z")

</div>

Export to e.g. my'name.htm actually writes to the filename **[ SYNTAX  
ERROR IN FORMATTING STRING ]**.

Workaround: replace ' with '' .

Whilst there's no mention of this restriction in Help, this discrepancy is a bug.

---

<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: [January 10, 2010, 1:06pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/2 "2010-01-10T13:06:05Z")

</div>

It's a format string so ' is treated as special character as explained at [https://docs.mp3tag.de/scripting](https://docs.mp3tag.de/scripting)

---

<div class="post-metadata">

### Author: ![chrisjj](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/a698b9/32.png) [@chrisjj](https://community.mp3tag.de/u/chrisjj)
#### Post date: [January 10, 2010, 1:18pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/3 "2010-01-10T13:18:43Z")

</div>

> It's a format string

Evidently so.

Whilst there's no mention of this in Help, this discrepancy is a bug.

---

<div class="post-metadata">

### Author: ![thaw04](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@thaw04](https://community.mp3tag.de/u/thaw04)
#### Post date: [January 12, 2015, 1:11pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/4 "2015-01-12T13:11:23Z")

</div>

I agree with chrisjj. The workaround also doesn't work for me though. For example, the action below gives me the same error because of the single quote:

Format value:  
GENRE  
$if($eql(%artist%,Ama'dou & Mariam),African,%genre%)

I tried it with the following workarounds but without a positive result:

- $if($eql(%artist%,"Ama'dou & Mariam"),African,%genre%)
- $if($eql(%artist%,Ama"dou & Mariam),African,%genre%)

It this possible in another way or should i stick with my workaround now (removing all the artist in the actions with an ' )

Thanks in advance

---

<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: [January 12, 2015, 3:19pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/5 "2015-01-12T15:19:34Z")

</div>

the single ' should become a double '  
Ama''dou & Mariam  
with 2 apostrophes should work

---

<div class="post-metadata">

### Author: ![chrisjj](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/a698b9/32.png) [@chrisjj](https://community.mp3tag.de/u/chrisjj)
#### Post date: [January 12, 2015, 3:50pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/6 "2015-01-12T15:50:12Z")

</div>

> [@thaw04](#):
>
> I agree with chrisjj. The workaround also doesn't work for me though. For example, the action below gives me the same error because of the single quote:
> 
> Format value:  
> GENRE  
> $if($eql(%artist%,Ama'dou & Mariam),African,%genre%)

That's a different case, and is expected behaviour give that the string is declared to be interpreted as a format string.

---

<div class="post-metadata">

### Author: ![thaw04](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@thaw04](https://community.mp3tag.de/u/thaw04)
#### Post date: [January 14, 2015, 5:41pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/7 "2015-01-14T17:41:47Z")

</div>

That did work, thanks a lot!!

---

<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: [December 28, 2018, 2:28pm UTC](https://community.mp3tag.de/t/x-single-quote-in-export-filename-causes-error/9632/8 "2018-12-28T14:28:04Z")

</div>

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