If it were up to me, I would not setup your sheet the way it is. But as you have things set up, try this formula in B8:

`=ArrayFormula(IFERROR(VLOOKUP(B7&B9,{A2:A5&C2:C5,B2:B5;A2:A5&E2:E5,D2:D5},2,FALSE),"NO MATCH"))`

The formula uses curly brackets to form a virtual array with the A2:A5 values concatenated with C2:C5, and to the right of that (in memory), the values from B2:B5. Underneath this array (as denoted by the semicolon), another array is formed with the A2:A5 values concatenated with the E2:E5 values this time, and to the right of that (in memory), the values from D2:D5. In the end, this array will contain just two columns: the first with the concatenations of every rows model with each possible vendor for that model, the second with the correlating size for that pairing.

The `VLOOKUP`

then concatenates your selected model and size from B7 and B9 and looks for it in the virtual array above. If that combination is found, the value in column 2 of the virtual array will be returned. If it is not, the `IFERROR`

will return “NO MATCH.”

The `FALSE`

in the `VLOOKUP`

means “My results aren’t in perfect ascending order and I’m looking for an exact match only.”