Hi there I am new to this formula so any help would be greatly appreciated.

I have multiple accounts with various sellers. I have summarized them into pivot table. What I need is a formula to pull from the pivot table all the names that fall under a certain account.

so if account 2 in A2 says this then pull
X
Y
Z
from the pivot table.
if in A2 it says 3
X
W
G.

How does a getpivotdata work and would it be able to pull all of them?

Thanks,