Help with formula, index match?

bubblepop

New Member
Joined
Feb 15, 2018
Messages
1
Hello,

I've been asked to help design a rota system but struggling with some of the more complicated formula's.
I've provided a mock example but the formula required would need to search a row for the date specified, then search that dates column for the dept number and return the staff member covering it. I just can't get my head round what formula is required.

Let me know if you need any more information.
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]1/04/2018[/TD]
[TD]02/04/2018[/TD]
[TD]03/04/2018[/TD]
[/TR]
[TR]
[TD]Staff 1[/TD]
[TD]Dept 1[/TD]
[TD]Dept 3[/TD]
[TD]Dept 2[/TD]
[/TR]
[TR]
[TD]Staff 2[/TD]
[TD]Dept 3[/TD]
[TD]Dept 1[/TD]
[TD]Dept 1[/TD]
[/TR]
[TR]
[TD]Staff 3[/TD]
[TD]Dept 2[/TD]
[TD]Dept 2[/TD]
[TD]Dept 3[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Date:[/TD]
[TD]User Input data[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Dept:[/TD]
[TD]User Input data[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Staff Member:[/TD]
[TD]Formula to return result[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Last used cell?
Press Ctrl+End to move to what Excel thinks is the last used cell.
Assuming your rota table starts from cell A1, try the following, confirming with ctrl+shift+enter:

=INDEX(A2:A4,MIN(IF(B1:D1=B8,IF(B2:D4=B9,ROW(A2:A4)-1))))
 
Upvote 0
Hi!

Another way in B8 and copy to the right:

=INDEX($A$2:$A$4,MATCH(B$7,INDEX($B$2:$D$4,,MATCH(B$6,$B$1:$D$1,)),))

Markmzz
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,327
Members
452,635
Latest member
laura12345

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