W
windsurferLA
I suspect this problem may be solved more simply with a pivot table,
but my users are having problems creating the pivot tables after they
build the data base.
Event data is recorded as pairs in a row where the first cell of the
pair contains the date and the second cell of the pair contains the
data. For example, the sheet where column A, row 9 indicates the hotel
(Hilton), column B will contain the formula, and columns C through L
will contain the data:
Hilton|formula| 1/11/1996 | $56 | 5/8/2004 | $89 |etc… to column “L”
I am looking for a formula that I can insert in column B on the same row
as the data stream which will ignore the dates and give me the sum of
all of the expenditures listed in that row (record).
My approach has been to use the SUMIF function in conjunction with the
“cell” function.
The “cell” function will return a code based on the format of a cell.
The formula shown below will yield a series of true and false answers
when entered into cells in the range D20:M20 (or any other row) based
on whether or not the corresponding cell in row 9 is set to display data
in the General format.
=("G"=CELL("format",D9:M9))
The SUMIF formula returns the WRONG answer when I then used this SUMIF
formula entered as a regular or array formula
{=SUMIF(C13:L13,C13:L13="TRUE",C9:L9)}
The formula returns the sums of the date code numbers.
The SUMIF yields the right answerif I enter as an array formula:
{=SUMIF(C13:L13,C13:L13<>"TRUE",C9:L9)}
The fact that the <> works implies there is some unseen column offset
issue.
When I try to go to the next step and build the cell format test into
eith normal or array configuration of the SUMIF formula,
=SUMIF(C9:L9, ("G"<>CELL("format",C9:L9)) ,C9:L9)
{=SUMIF(C9:L9, ("G"<>CELL("format",C9:L9)) ,C9:L9)}
I get zero as the sum whether I enter it as a regular formula or as an
array formula.
I also have tried using the SUM(IF …. ) in an array formula as.
{=SUM(IF(("G"=CELL("format",C9:L9)),C9:L9))}
{=SUM(IF(AND("G"=CELL("format",C9:L9)),C9:L9))}
{=SUM(IF(("G"<>CELL("format",C9:L9)),C9:L9))}
All yield zero sum.
SUGGESTIONS?
but my users are having problems creating the pivot tables after they
build the data base.
Event data is recorded as pairs in a row where the first cell of the
pair contains the date and the second cell of the pair contains the
data. For example, the sheet where column A, row 9 indicates the hotel
(Hilton), column B will contain the formula, and columns C through L
will contain the data:
Hilton|formula| 1/11/1996 | $56 | 5/8/2004 | $89 |etc… to column “L”
I am looking for a formula that I can insert in column B on the same row
as the data stream which will ignore the dates and give me the sum of
all of the expenditures listed in that row (record).
My approach has been to use the SUMIF function in conjunction with the
“cell” function.
The “cell” function will return a code based on the format of a cell.
The formula shown below will yield a series of true and false answers
when entered into cells in the range D20:M20 (or any other row) based
on whether or not the corresponding cell in row 9 is set to display data
in the General format.
=("G"=CELL("format",D9:M9))
The SUMIF formula returns the WRONG answer when I then used this SUMIF
formula entered as a regular or array formula
{=SUMIF(C13:L13,C13:L13="TRUE",C9:L9)}
The formula returns the sums of the date code numbers.
The SUMIF yields the right answerif I enter as an array formula:
{=SUMIF(C13:L13,C13:L13<>"TRUE",C9:L9)}
The fact that the <> works implies there is some unseen column offset
issue.
When I try to go to the next step and build the cell format test into
eith normal or array configuration of the SUMIF formula,
=SUMIF(C9:L9, ("G"<>CELL("format",C9:L9)) ,C9:L9)
{=SUMIF(C9:L9, ("G"<>CELL("format",C9:L9)) ,C9:L9)}
I get zero as the sum whether I enter it as a regular formula or as an
array formula.
I also have tried using the SUM(IF …. ) in an array formula as.
{=SUM(IF(("G"=CELL("format",C9:L9)),C9:L9))}
{=SUM(IF(AND("G"=CELL("format",C9:L9)),C9:L9))}
{=SUM(IF(("G"<>CELL("format",C9:L9)),C9:L9))}
All yield zero sum.
SUGGESTIONS?