Help

Re: IF AND For Two Conditons Not Working

Solved
Jump to Solution
656 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Kevin_Austin
5 - Automation Enthusiast
5 - Automation Enthusiast

I'm trying to get two conditons from two fields that contain certain text that if True produces a duration value.  I can get it to work work one condition but when I add the second it will not work.  Can someone see what I'm doing wrong?

 

This Formula works:
 
IF(FIND("ABC",Origin),3600,0)
 
But when I add the second condition it shows all 0's on the fields that contain "ABC" and the fields the doesn't contain"ABC" gets the 3600:
 
IF(AND(FIND("ABC",Origin)),AND(FIND("New",{Lane class}),3600,0))
 
Thanks

 

1 Solution

Accepted Solutions
Kenneth_Raghuna
7 - App Architect
7 - App Architect

I believe you are using the AND() function incorrectly. You do not need to call it twice, you just need to put both conditions within the function. (ie. AND(Condition 1, Condition 2))

This should work:

 

IF(AND(FIND("ABC",Origin), FIND("New",{Lane class})),3600,0)

 

See Solution in Thread

3 Replies 3
Kenneth_Raghuna
7 - App Architect
7 - App Architect

I believe you are using the AND() function incorrectly. You do not need to call it twice, you just need to put both conditions within the function. (ie. AND(Condition 1, Condition 2))

This should work:

 

IF(AND(FIND("ABC",Origin), FIND("New",{Lane class})),3600,0)

 

Kevin_Austin
5 - Automation Enthusiast
5 - Automation Enthusiast

Thanks for the reply, but now I don't get anything in the field.

Single parenthesis was out of place. I edited the response, should work now.