Anniversary filter not working

Your software
My Mautic version is: 3.3.2
My PHP version is: 7.3.27
My Database type and version is: MariaDB 10.5.8

Your problem
My problem is: I’ve created a custom field “Date of Birth” and added values to some contacts and then created a segment using the “anniversary” filter option as per this thread:

However, the segment never has any contacts added to it. I have set some today day and month, but in past years and believe they should be added. This is what the filter looks like in the Mautic interface:

I’ve tried running the segment update command manually, just to make sure it wasn’t the cron job not running, but that just gives the output:

Rebuilding contacts for segment 16
0 total contact(s) to be added in batches of 300
0 total contact(s) to be removed in batches of 300
0 contact(s) affected

Am I doing something wrong or is that previous thread wrong and this isn’t an option?

Looks like there is a Github issue for this regression already:

1 Like

Hi there

Have you tried do do this inside a campaign rather, there is a condition on date with operator date and value anniversary

That wouldn’t work would it? The campaign triggers when someone is added to it and unless their birthday fell on the day they were added to the campaign, that would just fail the condition.

Anyone the “work around” on the github ticket is to use:

anniversary +1 days

instead and that works.


The way that I have done this in the past is by having my All segment coming into the campaign. Then having a condition on field value if DOB equals Anniversary, if yes then send e-mail, then after send email a jump event back to original condition, if no jump event after 1 day and back to original condition.

The only thing with this is it might turn into a very heavy campaign depending on your DB size, so you might want to have a separate cronjob just to run this campaign, this is done with the extension -1 [campaign id] for your update and trigger

The segment seems to be working and only contains the contacts for that day and then using this segment in a campaign to send the email. I think overall this is a better approach and it is much less “work” for Mautic to do.

1 Like

We created a step by step guide for this.

Maybe this helps?