Forum Discussion
Fcin144
Apr 06, 2024Copper Contributor
Identify if multiple values exist in one cell
I am trying to determine if an email address is for a client, or it is not. So, for example our company email addresses are @nbc.com or abc.com I would like to know if any incoming email are ...
Fcin144
Apr 06, 2024Copper Contributor
Thank you for the reply. I am using Web Version 365.
I tried your recommended statement however it returned No when either abc.com or nbc.com was found. In addition, when any other email address was found it returned Yes.
=IF(OR(ISNA(XMATCH(TEXTAFTER(TEXTSPLIT(A2, ","), "@"), {"abc.com","nbc.com"}))), "Yes", "No")
I would like the Client Field in the spreadsheet that stores the cell and the statement to return "Yes" when any other email address besides abc.com or nbc.com is found using the statement.
Thanks again in advance.
djclements
Apr 06, 2024Bronze Contributor
Fcin144 wrote:I tried your recommended statement however it returned No when either abc.com or nbc.com was found.
The formula only returns "No" when ALL email addresses in the cell are company accounts (ALL domain names are either "abc.com" or "nbc.com").
Fcin144 wrote:In addition, when any other email address was found it returned Yes.
...
I would like the Client Field in the spreadsheet that stores the cell and the statement to return "Yes" when any other email address besides abc.com or nbc.com is found using the statement.
That's exactly what the formula does... when any non-company email address is found, it returns "Yes".
I'm afraid your question is unclear. What you want appears to conflict with what you don't want. It would help if you could provide a larger sample set that accurately and completely reflects your actual data, showing what the formula is currently returning for each scenario, plus a third column showing the expected results (manually type what the result should be and why).