=IF(AND(OR statement needed?

B

bracket89

How do i write a formula for the following? I am very close but keep having
problems getting it perfect. I've tried so many combos of If(or(and (w/
lookups, not( etc. but can't get it.

data already in spreadsheet:

column A can only either be "x" or "y".
column B can be any name
column C is a $ value
column D is list of particular names

Need single formula to say:
if A is "x" = return value from C no matter what
if A is "y" = return value from C ***unless B is on the list in D = then
return 0.

Thanks in advance!
 
M

Martin Fishlock

I think you want a formula like this assuming that the list is in te colum d
otherwise restrict the column

=IF(OR(A1="x",AND(A1="y",ISNA(MATCH(B1,$D:$D,0))=FALSE)),C1,"")
 
Top