richh
Board Regular
- Joined
- Jun 24, 2007
- Messages
- 245
- Office Version
- 365
- 2016
I am trying to match two sets of test scores to find what each student's highest score was in Test A when they took Test B. The expected results are shown in the last two columns of Test Set A. I think I need to do an INDEX MATCH, but I don't know how to incorporate selecting only the rows that have dates on or before the test taken an finding the max value from those selected.
Test Set A is as follows:
Test Set B is as follows:
Test Set A is as follows:
StudentID | TestName | TestScore | TestDate | HighestTestBMath | HighestTestBReading |
123 | Science | 100 | 8/1/2020 | 100 | 110 |
123 | Math | 99 | 9/1/2020 | 200 | 120 |
123 | Social Studies | 111 | 9/9/2020 | 300 | 120 |
Test Set B is as follows:
StudentID | TestName | TestScore | TestDate |
123 | Math | 100 | 7/7/2020 |
123 | Math | 200 | 8/7/2020 |
123 | Math | 300 | 9/7/2020 |
123 | Reading | 110 | 7/7/2020 |
123 | Reading | 99 | 7/7/2020 |
123 | Reading | 120 | 8/7/2020 |
123 | Reading | 100 | 9/4/2020 |