Forum Discussion
Deleted
Aug 02, 2019If cells equal then next returns
Hello, Could someone help me with a formula to produce the below: - If cell A1 has the word “apple” - and then cell B1 has the word “orange” - return the word “fruit” in cell C1 Thanks
- Aug 02, 2019
Deleted this formula in C1 should work
=IF(AND(B1="orange",A1="apple"),"fruit","not fruit")
Ruth de Groot
Aug 02, 2019Brass Contributor
Deleted this formula in C1 should work
=IF(AND(B1="orange",A1="apple"),"fruit","not fruit")
- DeletedAug 02, 2019Great, thank you - this worked!
- TwifooAug 02, 2019Silver ContributorThe required formula was premised on whether A1 HAS “apple” and B1 HAS “orange”, which must be construed as A1 INCLUDES “apple” and B1 INCLUDES “orange”.
If the premise of the formula would have been A1 IS “apple” and B1 IS “orange”, then such must be construed as A1 ONLY CONTAINS “apple” and B1 ONLY CONTAINS “orange”.
In stating that A1 HAS the word “apple”, you inevitably meant that A1 may also INCLUDE other characters other than the word “apple”, such that “pineapple”, “star apple”, or “apple juice” would have been also a valid content for A1.
Similarly, “sour orange”, sweet orange”, or “orange juice” would have been likewise a valid content for B1.
I hope you’ll appreciate the difference.- DeletedAug 02, 2019Thanks Twifoo.
I would like the formula to capture if cells A1 and B1 contain the word Apple or orange. So if cell A1 contains “Apple juice” and cell B1 contains “orange juice” I would like cell C1 to still return the value in the original post