If Multiple Conditions

beginvbaanalyst

Board Regular
Joined
Jan 28, 2020
Messages
139
Office Version
  1. 365
Platform
  1. Windows
Hi Everyone,

Struggling with three different scenarios; scenario one: if Column Row says "New" return "new", scenario two: if scenario one is true, but date is less than 2/1/2023 return "transfer", scenario three: if scenario one and two are true, if balance is greater than (>) past month balance return "balance went up"))).

My formula is currently this:
=IF([@UpdatedChange]="New",+IF([@OpenDate1]<DATE(2023,2,1),"transfer",+IF([@Balance]>VLOOKUP([@LoanID],'Jan23'!B:H,7,0),"balance went up")))

My returns are #N/A, False, and transfer.
What in my formula is causing this?
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
I suspect you can condense this further but try this:
PS: You will generally find you get a response is you provide some sample data for us to work with.

20230415 Nested If Statement beginvbaanalyst.xlsx
ABCDEFGH
1
2
3Col1UpdatedChangeOpenDate1BalanceLoanIDFormula
4AppleNew30/12/2022transfer
5PearOld30/12/2022Not New
6OrangeNew15/04/2023Not Found
7KiwiNot New
8
Sheet1
Cell Formulas
RangeFormula
G4:G7G4=IF([@UpdatedChange]="New", IF([@OpenDate1]<DATE(2023,2,1), "transfer", IFERROR( IF([@Balance]>VLOOKUP([@LoanID],'Jan23'!B:H,7,0), "balance went up", ""), "Not Found")), "Not New")
 
Upvote 0
I suspect you can condense this further but try this:
PS: You will generally find you get a response is you provide some sample data for us to work with.

20230415 Nested If Statement beginvbaanalyst.xlsx
ABCDEFGH
1
2
3Col1UpdatedChangeOpenDate1BalanceLoanIDFormula
4AppleNew30/12/2022transfer
5PearOld30/12/2022Not New
6OrangeNew15/04/2023Not Found
7KiwiNot New
8
Sheet1
Cell Formulas
RangeFormula
G4:G7G4=IF([@UpdatedChange]="New", IF([@OpenDate1]<DATE(2023,2,1), "transfer", IFERROR( IF([@Balance]>VLOOKUP([@LoanID],'Jan23'!B:H,7,0), "balance went up", ""), "Not Found")), "Not New")

Thank you for the help, this appears to work but I realize for the balance I need to vlookup the first part as well to make sure Im comparing exact data to exact data.
IFERROR(IF([@[Original Limit]]<VLOOKUP([@[Loan ID]],'Feb23'!B:H,6,0),"balance went up","")
I'm trying to adjust this to do a vlookup < vlookup but for some reason it's breaking, I can't get the balance went up to show up at all. My current formula is this: IFERROR(IF(VLOOKUP([@[Loan ID]],B:G,6,0)<VLOOKUP([@[Loan ID]],'Feb23'!B:H,6,0),"balance went up","")
 
Upvote 0
You might need to provide some sample data (ideally using XL2BB) with expected results.
I don't understand what you are looking up with this part
Excel Formula:
VLOOKUP([@[Loan ID]],B:G,6,0)
It seems to be looking up the current row ID against the table that row ID is in which doesn't make sesnse to me.
 
Upvote 0

Forum statistics

Threads
1,215,381
Messages
6,124,614
Members
449,175
Latest member
Anniewonder

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