# $strstr usage with combination literal & placeholders

**URL:** <https://community.mp3tag.de/t/strstr-usage-with-combination-literal-placeholders/41226>\
**Category:** Support\
**Created:** [March 28, 2018, 2:18pm UTC](https://community.mp3tag.de/t/strstr-usage-with-combination-literal-placeholders/41226 "2018-03-28T14:18:31Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![stephensimpson53](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/f14d63/32.png) [@stephensimpson53](https://community.mp3tag.de/u/stephensimpson53)\
**Post date:** [March 28, 2018, 2:18pm UTC](https://community.mp3tag.de/t/strstr-usage-with-combination-literal-placeholders/41226/1 "2018-03-28T14:18:31Z")

</div>

Value in tag CONTENTGROUP is "Energy 4"

I am trying to get $strstr to evaluate to something other than 0.  
Using a Format Value action, my script is:  
$strstr(%contentgroup%,Energy\s\d+)

Why doesn't the script evaluate to something greater than 0?

---

<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:** [March 28, 2018, 2:21pm UTC](https://community.mp3tag.de/t/strstr-usage-with-combination-literal-placeholders/41226/2 "2018-03-28T14:21:54Z")

</div>

> [@stephensimpson53](#):
>
> $strstr(%contentgroup%,Energy\s\d+)
> 
> Why doesn't the script evaluate to something greater than 0?

Because it is fairly like that you do not have the string "backslash-s-backslash-d-plus" in the field contentgroup.  
$strstr() only compares string constants or field variables that result in a string constant and no patterns.

See also the help on string functions:

> **[Scripting Functions – Mp3tag Documentation](https://docs.mp3tag.de/scripting/#string-functions)**
>
> Documentation on Mp3tag's scripting functions. 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:** [February 9, 2026, 12:27pm UTC](https://community.mp3tag.de/t/strstr-usage-with-combination-literal-placeholders/41226/3 "2026-02-09T12:27:19Z")

</div>


