# How to Remove Contact from Segment When They Join Another Segment

**URL:** https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671
**Category:** Product Support
**Created:** [November 18, 2021, 4:15pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671 "2021-11-18T16:15:40Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![bomx](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/bomx/32/6214_2.png) [@bomx](https://forum.mautic.org/u/bomx)
#### Post date: [November 18, 2021, 4:15pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671/1 "2021-11-18T16:15:40Z")

</div>

**Your software**  
My Mautic version is: 4.0.1  
My PHP version is: 7+  
My Database type and version is:

**Your problem**  
My problem is:

First, filters are not working to create segments.

How can I automatically remove a contact from a segment when they join a different segment?

Or is there a way to exclude segments when creating a “segment email/one time broadcast”?

Thanks

---

<div class="post-metadata">

### Author: ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)
#### Post date: [November 18, 2021, 4:17pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671/2 "2021-11-18T16:17:41Z")

</div>

1. Have you set up your cronjob for running segments: /var/www/mautic/bin/console Mautic:segments:update

2. You can create a segment and in the filters you can add a filter for segments exclude “the segment you want to have taken out”

---

<div class="post-metadata">

### Author: ![bomx](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/bomx/32/6214_2.png) [@bomx](https://forum.mautic.org/u/bomx)
#### Post date: [November 18, 2021, 4:36pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671/3 "2021-11-18T16:36:02Z")

</div>

Thank you Mike, I have not set up the cronjob.

---

<div class="post-metadata">

### Author: ![bomx](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/bomx/32/6214_2.png) [@bomx](https://forum.mautic.org/u/bomx)
#### Post date: [November 18, 2021, 5:22pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671/4 "2021-11-18T17:22:04Z")

</div>

> [@mikew](#):
>
> /var/www/mautic/bin/console Mautic:segments:update

Is this the proper way to set it up?

 ![Screen Shot 2021-11-18 at 12.21.30 PM](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/d/d75f752305f6ef7c851cd94ac5a2d6c56e1920e7.png)

---

<div class="post-metadata">

### Author: ![mikew](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mikew/32/5156_2.png) [@mikew](https://forum.mautic.org/u/mikew)
#### Post date: [November 18, 2021, 6:20pm UTC](https://forum.mautic.org/t/how-to-remove-contact-from-segment-when-they-join-another-segment/21671/5 "2021-11-18T18:20:23Z")

</div>

I think you need to put add php to the beginning of the command and I would use small M for mautic
