Nesting IF AND OR Functions

bstrange

New Member
Joined
Mar 4, 2009
Messages
2
Not sure where to go from here.

I am trying to write a formula that checks the following.
If A2=A3 is true AND B2=B3 is true OR if C2 contains the string "packet" then return "" in D2. If false then D2 = 10.

Another way to say it. If 2 consecutive order ID# are = AND 2 consecutive ship dates are =, OR description contains "packet" then Order charge = "". If not, then order charge = 10.

This is what I tried for D2, but didn't work.
=IF((A2=A3),IF((B2=B3),IF(SEARCH("PACKET",C2,1),"",10),10))

Thanks for any help. This one has got me stumped.<SCRIPT language=JavaScript src="http://www.interq.or.jp/sun/puremis...[/XD][XH][/XH][/XR][/RANGE][/XH][/XR][/RANGE]
 
Last edited:

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
Not sure why you're using search since you have no other text besides packet when it appears according to your sample, but you should not need NOT(ISERROR. ISNUMBER would accomplish the same thing.

=IF(OR(C2="packet",AND(A2=A3,B2=B3)),"",10)

If you actually need to search:

=IF(OR(ISNUMBER(SEARCH("packet",C2)),AND(A2=A3,B2=B3)),"",10)
 
Upvote 0

Forum statistics

Threads
1,215,029
Messages
6,122,757
Members
449,094
Latest member
dsharae57

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