Joining And with Or in an If Statement

Excel_77

Active Member
Joined
Sep 15, 2016
Messages
311
Office Version
  1. 2019
Platform
  1. Windows
Hi All,

The below code was working perfectly, however I want to add an extension to the formula to check that the football column = "yes" and the sport column = either "1" or "2" then I want "no" returned, otherwise go on to the next aspect of the formula.

=IF(Football_Column="Yes","12 Months"AND(Sport_Column="1"OR("2"),"No"),IF(Television_Column="Yes","Secure",IF(Rest_Column="Test","Check","Correct")))

How can I fix this?

Thanks in advance.
 
Last edited:

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
=IF(Football_Column="Yes",IF(OR(Sport_Column={1,2}),"No","12 Months"),IF(Television_Column="Yes","Secure",IF(Rest_Column="Test","Check","Correct")))
 
Upvote 0
=IF(Football_Column="Yes",IF(OR(Sport_Column={1,2}),"No","12 Months"),IF(Television_Column="Yes","Secure",IF(Rest_Column="Test","Check","Correct")))

Thanks but I think I made a mistake with my original code, is should have been as follows, can this still be done?


=IF(Football_Column="Yes",AND(Sport_Column="1(6)"OR("2(9)"),"No"),IF(Television_Column="Yes","Secure",IF(Rest_Column="Test","Check","Correct")))
 
Last edited:
Upvote 0
=IF(Football_Column="Yes",IF(OR(Sport_Column={"1(6)","2(9)"}),"No","12 Months"),IF(Television_Column="Yes","Secure",IF(Rest_Column="Test","Check","Correct")))
 
Upvote 0

Forum statistics

Threads
1,223,896
Messages
6,175,263
Members
452,627
Latest member
KitkatToby

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top