Pull Data From One Excel Sheet To Another Based on Lookup Values

Copper Contributor

Okay so let me preface, I am trying to make an excel spread sheet to track my option investments. To do so I would like to simply import my options data: stock symbol, prices, commissions, etc. Into an individual tab. I would then like to be able to use a sheet used a "search" tab where I could just punch in "AAL" and all transactions in my data sheet (be in 1 or 100) containing AAL would populate on the various data points I have in my data tab which I can then use for profitability calculations, etc.

 

How could I go about creating this type of sheet? I have been trying to use "VLOOKUP" but I am only able to get a singular occurrence, not populate all occurrences of said data points. Ex. =VLOOKUP(L2,A1:I33,7,) it will return the first $.54. But I am not sure how to return any other of the 3 trades data.

 

Below is an example of the imported data that would be inside the data sheet that I would like to see popular when when I look up that AAL symbol.

1 Reply

@Oxley123 If you are on MS365 or Excel 2021, use the FILTER function (Cell C2). If that's not an option, you'll need to revert to a more cumbersome formulae (Columns E:F). Both are demonstrated in the attached file. I've used named ranges to make the formulae easier to write, read and maintain. 

 

Alternatively, why not forget about the Search tab all-together? Do the search by filtering the desired symbol, directly in the transactions table.