Forum Discussion
PrettyDreamer
Nov 29, 2021Copper Contributor
Formula to ignore blanks
Hi There,
I am trying to do a formula of =A1=B1 but to ignore blank cells how do I do this?
| Code 1 | Code 2 | Match? |
| 833 | 834 | |
| 833 | 833 | |
| 833 | 837 |
So I would like the formula in column C. I would like it to come back with "Yes" if the two columns match and "No" if they do not match. But my normal formula of =A1=B2 is counting the blank row as "Yes" because technically they are the same. How do I get it to ignore these?
2 Replies
- OliverScheurichGold Contributor
=IF(AND(A2=B2,A2<>"",B2<>""),"Yes","No")
I would enter above formula in cell C2 and copy down.
- PrettyDreamerCopper ContributorYou are my saviour - thank you!