Need help with payroll index match formula

PROV226RV

New Member
Joined
Apr 1, 2013
Messages
31
I have taken the time to type out in excel the circular E for weekly married and monthly married tax table for federal withholding. I have one employee that I have to do a weekly payroll check for and he also gets a monthly commission check based on sales. With that being said, I don't want to have to look up his withholding rate everytime I run payroll. I need to have excel look for the right amount based on the following info that is on the same sheet.

So if I have W in the first column, then excel needs to search the Weekly Withholding table and if it is M, then the monthly withholding table. However, my tax table has 2 values for wage range ... "at least this amount" and "but less than this amount". I have it searching the second value and looking for an approximate match that is less than.

I know how to create one formula to lookup the value with index/match, but I dont know how to make it "IF W then look at this table" or "if M then look at that table".

IF($AN13=0,0,INDEX(W_WH,MATCH($AN13,$Q$142:$Q$277,1),MATCH($M$6,$P$4:$AB$4)))

where
AN13 = salary payrrate
W_WH = range to index for weekly married wages
Q142:Q277 = greateer of the 2 wage values
M6 = # of withholding allowances on W-4 form for employee
P4:AB4 = # of withholding allowance header on table


The "
IF AN13 = 0" is where I need excel to look at W/M column (starting in AF13) and determine if W then formula I listed above, but if M then this formula:


INDEX(M_WH,MATCH($AN13,$Q$6:$Q$141,1),MATCH($M$6,$P$4:$AB$4)))


Any ideas on how to insert that?

Thanks

Rachel V in Florida
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
You would want to nest one formula inside the other one...

Try this, It may work...( I don't have all the data to see if it works )

=IFERROR(IF($AN13=0,0,IF($AN13="W",INDEX(W_WH,MATCH($AN13,$Q$142:$Q$277,1),MATCH($M$6,$P$4:$AB$4)),INDEX(M_WH,MATCH($AN13,$Q$6:$Q$141,1),MATCH($M$6,$P$4:$AB$4)))),0)
 
Upvote 0
You would want to nest one formula inside the other one...

Try this, It may work...( I don't have all the data to see if it works )

=IFERROR(IF($AN13=0,0,IF($AN13="W",INDEX(W_WH,MATCH($AN13,$Q$142:$Q$277,1),MATCH($M$6,$P$4:$AB$4)),INDEX(M_WH,MATCH($AN13,$Q$6:$Q$141,1),MATCH($M$6,$P$4:$AB$4)))),0)

Yes it did work! Thanks so much
 
Upvote 0

Forum statistics

Threads
1,216,033
Messages
6,128,427
Members
449,450
Latest member
gunars

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