Extract column data by date

Simont485

Board Regular
Joined
May 19, 2018
Messages
50
ON spread sheet 1
I have a row of dates lets say B1:AB1
In A2:A8 I have a list of names.
In the cells B2:AB8 are letters representing shifts

On Spreadsheet 2
I have the same list of names
In B1 I want to enter a date the matches one of the dates on spreadsheet 1
in B2:B8 I want to see the left most letter that appear under that date in spreadsheet 1

When I change the date the data changes correspondingly.....


Basically one Column of shifts under one date instead of hunting for one date out of 365 columns of shifts
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Try:

All on sheet2

In B1 use Data Validation \ list \ with Source =Sheet1!$B$1:$AB$1

and formula in in B2 copy down
=INDEX(Sheet1!$A:$AB,MATCH(Sheet2!$A2,Sheet1!$A:$A,0),MATCH($B$1,Sheet1!$A$1:$AB$1,0))
 
Upvote 0
Wow that works!! Thank you.......but(sorry there had to be one:mad:)

If there is an empty cell I need it to be blank and not 0. Also I would like to show the left most character from sheet 1 only..

Thank you in advance
 
Last edited:
Upvote 0
In B2 copy down
=SUBSTITUTE(LEFT(INDEX(Sheet1!$B:$AB,MATCH(Sheet2!$A2,Sheet1!$A:$A,0),MATCH($B$1,Sheet1!$B$1:$AB$1,0)),1),0,"")
 
Last edited:
Upvote 0
This shorter formula should also work

=LEFT(INDEX(Sheet1!$B:$AB,MATCH(Sheet2!$A2,Sheet1!$A:$A,0),MATCH($B$1,Sheet1!$B$1:$AB$1,0)))
 
Upvote 0

Forum statistics

Threads
1,224,900
Messages
6,181,635
Members
453,059
Latest member
jkevin

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