# Compare the content of tags to look for matches

**URL:** <https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522>\
**Category:** Support\
**Created:** [January 18, 2015, 6:37pm UTC](https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522 "2015-01-18T18:37:55Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Quisquose](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/q/ea666f/32.png) [@Quisquose](https://community.mp3tag.de/u/Quisquose)\
**Post date:** [January 18, 2015, 6:37pm UTC](https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522/1 "2015-01-18T18:37:55Z")

</div>

OK, my final question for today 🙂

I've seen methods to remove duplicate tags, but I would like an action that does the following:

Compare ARTIST and ALBUMARTIST fields. If their content is the same then delete the ALBUMARTIST tag, but if their content differs then leave both tags in place.

Thanks.

---

<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:** [January 18, 2015, 6:52pm UTC](https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522/2 "2015-01-18T18:52:42Z")

</div>

> [@Quiquose](#):
>
> Compare ARTIST and ALBUMARTIST fields. If their content is the same then delete the ALBUMARTIST tag, but if their content differs then leave both tags in place. Thanks.

**ALBUMARTIST \<== $if($eql(%ARTIST%,%ALBUMARTIST%),,%ALBUMARTIST%)**

... or ...

**ALBUMARTIST \<== $if($eql($lower(%ARTIST%),$lower(%ALBUMARTIST%)),,%ALBUMARTIST%)**

DD.20150118.2130.CET

---

<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 18, 2015, 7:07pm UTC](https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522/3 "2015-01-18T19:07:45Z")

</div>

> [@Quiquose](#):
>
> OK, my final question for today 🙂
> 
> I've seen methods to remove duplicate tags, but I would like an action that does the following:
> 
> Compare ARTIST and ALBUMARTIST fields. If their content is the same then delete the ALBUMARTIST tag, but if their content differs then leave both tags in place.
> 
> Thanks.

this is the basic expression:  
$if($eql(%artist%,%albumartist%),1,0)

BUT: if you delete the ALBUMARTIST you will get problems on most players in respect to grouping albums together.

Also, I would use a filter as this means that only the hits are treated and not every file get evaluated.  
And then it is even simpler to remove fields.

So, to get rid of a field:  
Format value for ALBUMARTIST  
Format value: $if($eql(%artist%,%albumartist%),'',%albumartist%)

---

<div class="post-metadata">

**Author:** ![Quisquose](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/q/ea666f/32.png) [@Quisquose](https://community.mp3tag.de/u/Quisquose)\
**Post date:** [January 18, 2015, 8:41pm UTC](https://community.mp3tag.de/t/compare-the-content-of-tags-to-look-for-matches/16522/4 "2015-01-18T20:41:11Z")

</div>

Thank you both very much for all your help.

---

<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/compare-the-content-of-tags-to-look-for-matches/16522/5 "2026-02-09T12:25:28Z")

</div>

Closed on February 9, 2026, 12:25pm UTC


