Formula which will populate a second cell if the first intended cell is already populated?

Noswen869

New Member
Joined
Jul 18, 2023
Messages
11
Office Version
  1. 2021
Platform
  1. Windows
I am currently having to manually enter the dates that an employee has a meeting onto a central spreadsheet. I am looking for a way in which excel can do this for me automatically, probably via a vlookup of some kind.

I can download a spreadsheet of the data which will include the employee number (which the main sheet also uses) alongside the date of the meeting. This works fine when an employee has just the one meeting on the downloaded data sheet as a simple vlookup will automatically populate the 'Meeting 1' cell on the main sheet.

However my issue is when an employee has two or three meetings on the downloaded data sheet. I therefore need excel to populate the earliest date into 'Meeting 1' column on the main spreadsheet, the next date into 'Meeting 2' column on the main spreadsheet and so on etc.

Apologies if this does not format properly as this is the first time I'm attempting to use XLS2BB - here is a basic mock version of what the downloaded data sheet will look like:
Book1
AB
1Emp. NumberMeeting Date
21231/1/22
32345/10/22
43459/20/22
51235/15/23
623412/8/23
73454/29/23
Sheet2

Here is a mock version of what the main central spreadsheet will look like - this is where I would like the meeting dates to show:
Book1
ABCD
1Emp. NumberMeeting Date 1Meeting Date 2Meeting Date 3
2123
3234
4345
Sheet1
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Upvote 0
Another option
Fluff.xlsm
ABCD
1Emp. NumberMeeting Date 1Meeting Date 2Meeting Date 3
212301/01/202215/05/2023
323410/05/202208/12/2023
434520/09/202229/04/2023
Sheet1
Cell Formulas
RangeFormula
B2:C4B2=TRANSPOSE(FILTER(Sheet2!$B$2:$B$100,Sheet2!$A$2:$A$100=A2))
Dynamic array formulas.
 
Upvote 0
Another option
Fluff.xlsm
ABCD
1Emp. NumberMeeting Date 1Meeting Date 2Meeting Date 3
212301/01/202215/05/2023
323410/05/202208/12/2023
434520/09/202229/04/2023
Sheet1
Cell Formulas
RangeFormula
B2:C4B2=TRANSPOSE(FILTER(Sheet2!$B$2:$B$100,Sheet2!$A$2:$A$100=A2))
Dynamic array formulas.
Really appreciate this - thanks so much. Any chance you'd be able to explain the formula so i can make sense of it? Appreciate that required a bit of effort but i would be very grateful
 
Upvote 0
The filter function filters the data in sheet2 to return only what matches A2 & the transpose function converts it from a vertical list to a horizontal one.
 
Upvote 0
We see that you had cross-posted this question at: Formula to populate a secondary cell if the first intended cell is already populated
Cross-posting (posting the same question in more than one forum) is not against our rules, but the method of doing so is covered by #13 of the Forum Rules.

Be sure to follow & read the link at the end of the rule too!

Cross posted at:
There is no need to repeat the link(s) provided above but if you have posted the question at other places, please provide links to those as well.

If you do cross-post in the future and also provide links, then there shouldn’t be a problem.
 
Upvote 0
The filter function filters the data in sheet2 to return only what matches A2 & the transpose function converts it from a vertical list to a horizontal one.
If I needed to add a column inbetween the different Meeting Columns, for example 'Meeting Column 1 > Extra Column to mark whether they attended or not > Meeting Column 2' etc etc then how would I amend the formula to account for this? Or is this not possible
 
Upvote 0
Please post some data & expected results.
 
Upvote 0
Please post some data & expected results.
Sure:

I want my main tab to look like this - but I want the meeting dates to be pulled through from the secondary tab
Book1
ABCDEFGHI
1Emp. NumberMeeting Date 1Seen/DNAMeeting Date 2Seen/DNAMeeting Date 3Seen/DNAMeeting Date 4Seen/DNA
211/1/231/6/231/11/231/16/23
321/2/231/7/231/12/231/17/23
431/3/231/8/231/13/231/18/23
541/4/231/9/231/14/231/19/23
651/5/231/10/231/15/231/20/23
Sheet3


The secondary tab with the meeting dates is here:
Book1
AB
1Emp. NumberMeeting Date
21Sunday, 1 January 2023
32Monday, 2 January 2023
43Tuesday, 3 January 2023
54Wednesday, 4 January 2023
65Thursday, 5 January 2023
71Friday, 6 January 2023
82Saturday, 7 January 2023
93Sunday, 8 January 2023
104Monday, 9 January 2023
115Tuesday, 10 January 2023
121Wednesday, 11 January 2023
132Thursday, 12 January 2023
143Friday, 13 January 2023
154Saturday, 14 January 2023
165Sunday, 15 January 2023
171Monday, 16 January 2023
182Tuesday, 17 January 2023
193Wednesday, 18 January 2023
204Thursday, 19 January 2023
215Friday, 20 January 2023
Sheet4
 
Upvote 0

Forum statistics

Threads
1,215,071
Messages
6,122,963
Members
449,094
Latest member
Anshu121

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