R
Ray
Hello -
I've created a sheet that allows users to see data for a specific
month. They choose the month from a drop-down in cell A3 -- an INDEX
function converts this into a column reference on the Data sheet. The
Data sheet is structured like this:
Col A: Store #
Col B: Account #
Col C: Store & Account (concat'd)
Col D-R: data by month, Total (and a couple of other sums)
Col C contains a unique Store/Acct combination, so I'm able to use
this formula (on the report page) to get the correct figures:
=IF(ISERROR(VLOOKUP(Z$7&$A8,'Store Data_TY'!$A$2:$R$5000,$C$3,FALSE)),
0,VLOOKUP(Z$7&$A8,'Store Data_TY'!$A$2:$R$5000,$C$3,FALSE))
where:
Z7: store #
A8: acct #
C3: column reference
This all works fine -- my issue is that there is one scenario where I
need to SUM the values for 2 stores! I need to be able to see them
separately, but most of the time they should be added. If not for the
changing column reference, I could use SUMIF ... but how would I build
it to incorporate the changing column reference?
I think my answer lies with an ARRAY formula, but these things always
confuse me ....
Any ideas?
TIA,
ray
I've created a sheet that allows users to see data for a specific
month. They choose the month from a drop-down in cell A3 -- an INDEX
function converts this into a column reference on the Data sheet. The
Data sheet is structured like this:
Col A: Store #
Col B: Account #
Col C: Store & Account (concat'd)
Col D-R: data by month, Total (and a couple of other sums)
Col C contains a unique Store/Acct combination, so I'm able to use
this formula (on the report page) to get the correct figures:
=IF(ISERROR(VLOOKUP(Z$7&$A8,'Store Data_TY'!$A$2:$R$5000,$C$3,FALSE)),
0,VLOOKUP(Z$7&$A8,'Store Data_TY'!$A$2:$R$5000,$C$3,FALSE))
where:
Z7: store #
A8: acct #
C3: column reference
This all works fine -- my issue is that there is one scenario where I
need to SUM the values for 2 stores! I need to be able to see them
separately, but most of the time they should be added. If not for the
changing column reference, I could use SUMIF ... but how would I build
it to incorporate the changing column reference?
I think my answer lies with an ARRAY formula, but these things always
confuse me ....
Any ideas?
TIA,
ray