![]() |
Look up info in a database using 2 conditions
I have 2 different data sets (ranges/matrices). Data set Able has 2 columns
(fields) and 25 rows (observations), and data set Baker has, say, 10 columns and 1,000 rows. I want to write a formula that returns the value in the 6 th column of Data set Baker where the value in column 1 of Data set Baker matches the value in the cell at the intersection of row 23, column 1 of Data set Alpha AND the value in column 2 of Data set Baker matches the value in the cell at the intersection of row 23, column 2 in Data set Alpha. In other words, I want to lookup a value in the first data set where the values in columns 1 and 2 match the values in columns 1 and 2 of row 23 of the second data set. Actually, I want to copy a set of the desired function/formula down the side of Data Set Alpha to see if Data Set Baker has matches on both conditions for each observation in Data Set Alpha, and if so, to return the value in the matching row but in an adjacent column from Data Set Baker. Logically, if one or more values in column 1 in Data set Baker equal the value in cell A23, AND if one or more values in column 2 in Data set Baker equal the value in cell B23, and if the match is unique (only one row (observation) in Data Set Baker has matches in both columns), then give me the value in column 6 of the Data set Baker row that contains the matches. The lookup functions do this easily with only one criteria, and the dfunctions seem like they would do it except I can't figure out how to make them work because they require the column labels to be part of the criteria, and this prevents one from copying the formula down the side of Data set Alpha. Thanks a million! |
All times are GMT +1. The time now is 01:27 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com