Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Modifying a Formula 1

Status
Not open for further replies.

jatolo

MIS
Jul 17, 2006
40
US
This formula is working PERFECT....
=IF((P4=1)*(R4=1)*AND(T4=1),1,0)

NOW I NEED TO ADD "C1"... I MEAN...
P4="1 RA4=1 T4=1,1,0
P4="C1" RA4=1 T4=1,1,0
P4=1 RA="C1" T4=1,1,0
P4=1 RA=1 T4=C1,1,O
P4"C1" RA"C1" T4"C1",1,0... in other words count "c1" as 1
thank you!!

Thanks....
Jatolo
 

hi,

your formula is really NOT correct. The AND function works like this (check HELP)
[tt]
AND(expression1,expression2...,expressionn)
[/tt]
So I suspect that you wanted this...
[tt]
=IF(AND((P4=1),(R4=1),(T4=1)),1,0)
[/tt]
Now then, the new requirment is that P4 must either be 1 OR "C1", etc. So we will have ORs within the AND, and I will also remove the unnecessary parentheses...
[tt]
=IF(AND(OR(P4=1,P4="C1"),OR(R4=1,R4="C1"),OR(T4=1,T4="C1")),1,0)
[/tt]


Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top