# Check if a string contains another string

**URL:** <https://community.mp3tag.de/t/check-if-a-string-contains-another-string/50828>\
**Category:** Support\
**Created:** [November 18, 2020, 5:09pm UTC](https://community.mp3tag.de/t/check-if-a-string-contains-another-string/50828 "2020-11-18T17:09:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![georgeor](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/g/85e7bf/32.png) [@georgeor](https://community.mp3tag.de/u/georgeor)\
**Post date:** [November 18, 2020, 5:09pm UTC](https://community.mp3tag.de/t/check-if-a-string-contains-another-string/50828/1 "2020-11-18T17:09:51Z")

</div>

In short: I appended the FLAC MD5 audio checksum to the Comment tag and now I'd like to be able to verify if they match, that is, if the Comment tag contains that exact MD5 value. (Useful for future conversions.)

I don't want to modify the files in any way, this is just for checking.  
I found a somewhat similar problem with a neat solution [here](https://community.mp3tag.de/t/using-if-function-to-compare-2-columns/14552):

```
$if($eql(%artist%,%albumartist%),'ok','problem')

```

Is there a way to modify this, so that it doesn't check if the two columns are equal, but instead checks if one contains the other?

EDIT: Never mind, I think I got it.  
` $ifgreater($strstr(%comment%,%_md5audio%),0,yes,no)`

It was even in the help examples, but for some reason it didn't work when I first tried it.  
Let me know if there's a better solution, though.

---

<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:** [November 18, 2020, 6:10pm UTC](https://community.mp3tag.de/t/check-if-a-string-contains-another-string/50828/2 "2020-11-18T18:10:43Z")

</div>

Something similar has been discussed just 4 days ago:

> [@Filter to identify files with differences in artist tag and filename](https://community.mp3tag.de/t/filter-to-identify-files-with-differences-in-artist-tag-and-filename/50794):
>
> I am sure that this has been asked already before, i already found some similar topics but i probably do something wrong and the expressions i found are not working! What i want is to compare the artist tag to filename to identify files which they don't include the artist tag in the filename.

---

<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:** [December 30, 2020, 5:35pm UTC](https://community.mp3tag.de/t/check-if-a-string-contains-another-string/50828/3 "2020-12-30T17:35:03Z")

</div>

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