1

Scenario:

frank@example.com and alice@example.com belong to google group hr@example.com. Both of them send important memos to the whole company.

Until today, I had been able to search for important HR messages by filtering in gmail with this filter:

from:frank@example.com OR from:alice@example.com

Problem is, there is a new member of HR bob@example.com. He also sends mail to all employees, he also belongs to group hr@example.com.

I hate maintaining my filters. I am looking for a filter that will allow me to find email from anyone that belongs to group hr@example.com. I was looking for something like this:

from:hr@example.com

This doesn't work though, I get zero results with this filter.

Does anybody know if there is a way to filter email by members of google groups in gmail?

Note: I am aware that they could in theory send email using as sender the group hr@example.com. They don't however, and I am not campaigning for them to change.

Thanks for your help.

1 Answers1

0

The only way I've found so far is - if you have permissions to view the membership of the group in question - to make a static filter with the search operator OR, like from:email1@domain.ext OR from:email2@domain.ext etc. for all the members of the group.

Sadly, this is cumbersome and does not update with changes in group membership in e.g. an email filter rule.

Hopefully, someone has a better solution using maybe Google Apps Script or Google updates its GMail search to traverse list/group memberships.

Sources: https://groups.google.com/g/gmail-power-users/c/aHnG4O2yVSI/m/BXFexjiCCwAJ https://support.google.com/mail/answer/7190?hl=en

PS: You could add some regex like "(?=>)(.*?)(?<=<)" and replace all instances with " OR from:" in for example VS Code to get a list with only email addresses except some characters to manually edit in the beginning and end of the copied group member list text.

Vegz78
  • 11