Handling Multiple (unknown number of) Matches

Luke777

Board Regular
Joined
Aug 10, 2020
Messages
246
Office Version
  1. 365
Platform
  1. Windows
Hi all :)
I have a sheet containing dates, an associated name with a given date (let's pretend they are bookings for something - just to keep it simple) followed by three columns containing data associated with the booking.

What I would like to do is display the booking information starting in G2 (there will be a maximum of 6 bookings per date).

With tasks like this in the past, I have used a formula something along the lines of OFFSET(MATCH(TODAY(),A:A)...

However, I'm not sure how to work such a formula when the OFFSET parameters need change to reflect that there might only be one booking or there might be 6- so rows and col need to be changed dynamically.

Ideally, I would have blank spaces on the booking sheet, but unfortunately I don't have access to change how the booking sheet itself functions.

Any suggestions on how to dynamically change the offset parameters would be useful - though I'm fairly certain there may be a less complicated/better solution to this.

Thanks for your help!

Book4.xlsx
ABCDEFG
1DateNameData 1Data 2Data 323/10/2021
223/10/2021Daveteabluecat
323/10/2021Christeagreendog
423/10/2021Petercoffeeorangechicken
524/10/2021Rebeccatearedcow
625/10/2021Lolacoffeepinkdog
725/10/2021Davecoffeepurplepenguin
825/10/2021Daniellecoffeeredcat
925/10/2021Lucytearedcat
1025/10/2021Oliviateabluedog
1126/10/2021Davecoffeegreenpenguin
1228/10/2021Peterteabluesheep
1328/10/2021Oliviacoffeebluehamster
Sheet1
Cell Formulas
RangeFormula
G1G1=TODAY()
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Try this, copied down and across. Note that with your Excel version the formula should be confirmed with Ctrl+Shift+Enter, not just Enter

21 10 23.xlsm
ABCDEFGHIJ
1DateNameData 1Data 2Data 323/10/2021
223/10/2021DaveteabluecatDaveteabluecat
323/10/2021ChristeagreendogChristeagreendog
423/10/2021PetercoffeeorangechickenPetercoffeeorangechicken
524/10/2021Rebeccatearedcow    
625/10/2021Lolacoffeepinkdog    
725/10/2021Davecoffeepurplepenguin    
825/10/2021Daniellecoffeeredcat
925/10/2021Lucytearedcat
1025/10/2021Oliviateabluedog
1126/10/2021Davecoffeegreenpenguin
1228/10/2021Peterteabluesheep
1328/10/2021Oliviacoffeebluehamster
14
Luke777
Cell Formulas
RangeFormula
G1G1=TODAY()
G2:J7G2=IFERROR(INDEX(B:B,SMALL(IF($A$2:$A$100=$G$1,ROW(B$2:B$100)),ROWS(G$2:G2))),"")
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Solution
Try this, copied down and across. Note that with your Excel version the formula should be confirmed with Ctrl+Shift+Enter, not just Enter

21 10 23.xlsm
ABCDEFGHIJ
1DateNameData 1Data 2Data 323/10/2021
223/10/2021DaveteabluecatDaveteabluecat
323/10/2021ChristeagreendogChristeagreendog
423/10/2021PetercoffeeorangechickenPetercoffeeorangechicken
524/10/2021Rebeccatearedcow    
625/10/2021Lolacoffeepinkdog    
725/10/2021Davecoffeepurplepenguin    
825/10/2021Daniellecoffeeredcat
925/10/2021Lucytearedcat
1025/10/2021Oliviateabluedog
1126/10/2021Davecoffeegreenpenguin
1228/10/2021Peterteabluesheep
1328/10/2021Oliviacoffeebluehamster
14
Luke777
Cell Formulas
RangeFormula
G1G1=TODAY()
G2:J7G2=IFERROR(INDEX(B:B,SMALL(IF($A$2:$A$100=$G$1,ROW(B$2:B$100)),ROWS(G$2:G2))),"")
Press CTRL+SHIFT+ENTER to enter array formulas.
Brilliant! Thank you for this :) Seems to do exactly what I wanted! Thank you!
 
Upvote 0
You're welcome. Thanks for the follow-up. :)
 
Upvote 0

Forum statistics

Threads
1,215,066
Messages
6,122,948
Members
449,095
Latest member
nmaske

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