# Excel Formula with Multiple Criteria

I need a formula check if a Column C1 or C2 = “No” & C3= “LOAN” & C4 contain “XYZ” if yes then TDDL , if no TDL and all other cells blank
###### Who is Participating?

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Excel & VBA ExpertCommented:

``````=IF(AND(OR(C1="No",C2="No"),C3="LOAN",C4="XYZ"),"TDDL","TDL")
``````
0
Finance AnalystCommented:
Try this:
=IF(AND(OR(C1="No",C2="No"),C3="Loan",C4="*XYZ*"),"TDDL","TDL")
0
Author Commented:
Both Solutions are close, but I want fields to be blank if C3 does Not equal LOAN
0
Excel & VBA ExpertCommented:
Try this...

=IF(C3="LOAN",IF(AND(OR(C1="No",C2="No"),COUNTIF(C4,"*XYZ*")),"TDDL","TDL"),"")
0
Author Commented:
Neeraj,
I used a variation of the formula as follows:
=IF(S2="LOAN",IF(AND(OR(Q2="No",R2="No", IFERROR(SEARCH("PDM", P2),0)=0),"TDDL","TDL"),"")

Problem is I discovered another string text to account for , how do modify and add CIF to the search?
0
Excel & VBA ExpertCommented:
This is not a right way of asking a question.

Your existing formula isn't clear enough to tell what exactly you are trying to achieve.

BTW give this a try and tweak it as per your requirement.

``````=IF(S2="LOAN",IF(AND(OR(Q2="No",R2="No"),OR(ISNUMBER(SEARCH({"CIF","PDM"}, P2)))),"TDDL","TDL"),"")
``````
1

Experts Exchange Solution brought to you by

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Author Commented:
In box me of how I should have asked the question, please or email cfhasan1@aol.com
0
Author Commented:
Perfect!
1
Excel & VBA ExpertCommented:
What I meant, you changed the cell references as well as the criteria. These formulas specially with multiple criteria and without having a sample workbook are tricky one to derive sometimes. You should finalize your question before asking it. That's it. :)

Glad it worked as desired in the end. :)
0
Author Commented:
Understood and appreciate the feedback
1
###### It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Applications

From novice to tech pro — start learning today.