A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data
You are welcome:) You may also give feedback on it.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi, I am trying to auto reference information in a table from data generated in another table, this is for a table seating arrangement for an event, where I would plan all the guests' seating arrangement, and hope to auto-reference these information to another sheet which is the attendance taking sheet, where the list of guests would have their table number automatically referenced from the seating arrangement sheet to ensure accuracy.
I have two sheets.
Sheet 1: A table showing all the seating arrangement for guests;
Sheet 2: A list showing attendance taking sheet of all guests, and their table number.
It seems XLOOKUP doesn't work, as for XLOOKUP it is not possible to search in a horizontal array and return values from a vertical array.
All guests' names have been made to match the information on all sheets to ensure correct referencing.
Can anyone advice please?
Thank you.
A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data
Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.
Answer accepted by question author
Sheet1!$E$5:$K$16=M6:
E5:K16 on Sheet1 is equal to the value in cell M6.TRUE and FALSE values. TRUE where the cell matches M6, and FALSE where it doesn't.--(Sheet1!$E$5:$K$16=M6):
--) converts the TRUE and FALSE values into 1 and 0 respectively. This is known as a double unary operator.TRUE becomes 1 and FALSE becomes 0.BYCOL(--(Sheet1!$E$5:$K$16=M6), LAMBDA(a, SUM(a))):
BYCOL applies a function to each column of the array.LAMBDA(a, SUM(a)) is a custom function that sums the values in each column.1s and 0s in each column, resulting in an array where each element is the sum of matches in that column.BYCOL(--(Sheet1!$E$5:$K$16=M6), LAMBDA(a, SUM(a))) > 0:
0.TRUE and FALSE values. TRUE where there is at least one match in the column, and FALSE where there are no matches.XLOOKUP(TRUE, ..., Sheet1!$E$4:$K$4):
XLOOKUP searches for the first TRUE in the array created by the previous step.TRUE, it returns the corresponding value from the range E4:K4 on Sheet1.Just did, thank you again.
Would you mind explaining in detail how this works like teaching a school student? This works really well and I'm trying to understand what each of the little bit of the formula does and mean.
Thank you again for your wonderful help.
Wow! That worked a treat, thank you very much indeed!
Wish you a good day.