ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   IF and VLookup (https://www.excelbanter.com/excel-worksheet-functions/113038-if-vlookup.html)

Ashley

IF and VLookup
 
Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am trying
to perform the sum function for all the amounts in column R that have a D in
column S and a sum for all the amounts in column R that have a C in column S.
Is it possible to combine the SUM and IF/VLookup functions?

PCLIVE

IF and VLookup
 
You don't need lookup. Try this:

=SUMIF(S:S,"D",R:R)

=SUMIF(S:S,"C",R:R)

HTH,
Paul

"Ashley" wrote in message
...
Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am
trying
to perform the sum function for all the amounts in column R that have a D
in
column S and a sum for all the amounts in column R that have a C in column
S.
Is it possible to combine the SUM and IF/VLookup functions?




Teethless mama

IF and VLookup
 
=SUMIF(S1:S100,"D",R1:R100)

=SUMIF(S1:S100,"C",R1:R100)


"Ashley" wrote:

Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am trying
to perform the sum function for all the amounts in column R that have a D in
column S and a sum for all the amounts in column R that have a C in column S.
Is it possible to combine the SUM and IF/VLookup functions?


Bob Phillips

IF and VLookup
 
=SUMPRODUCT((D1:D10={"D","C",""})*(R1:R10))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Ashley" wrote in message
...
Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am

trying
to perform the sum function for all the amounts in column R that have a D

in
column S and a sum for all the amounts in column R that have a C in column

S.
Is it possible to combine the SUM and IF/VLookup functions?




Bob Phillips

IF and VLookup
 
or even

=SUMPRODUCT(SUMIF(D1:D10,{"C","D",""},R1:R10))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Ashley" wrote in message
...
Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am

trying
to perform the sum function for all the amounts in column R that have a D

in
column S and a sum for all the amounts in column R that have a C in column

S.
Is it possible to combine the SUM and IF/VLookup functions?




Ashley

IF and VLookup
 
Thank you! I completely forgot about SUMIF

"Teethless mama" wrote:

=SUMIF(S1:S100,"D",R1:R100)

=SUMIF(S1:S100,"C",R1:R100)


"Ashley" wrote:

Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am trying
to perform the sum function for all the amounts in column R that have a D in
column S and a sum for all the amounts in column R that have a C in column S.
Is it possible to combine the SUM and IF/VLookup functions?


Ashley

IF and VLookup
 
Thank you! I completely forgot about SUMIF

"PCLIVE" wrote:

You don't need lookup. Try this:

=SUMIF(S:S,"D",R:R)

=SUMIF(S:S,"C",R:R)

HTH,
Paul

"Ashley" wrote in message
...
Any help is greatly appreciated.

In column S, I have either a D, a C, or a blank. Below my data I am
trying
to perform the sum function for all the amounts in column R that have a D
in
column S and a sum for all the amounts in column R that have a C in column
S.
Is it possible to combine the SUM and IF/VLookup functions?





Carim

IF and VLookup
 
Hi Ashley,

With an array formula ( Ctrl+Shift+Enter and not just Enter )
adjust ranges to your needs ...

=SUM(IF(S2:S20="D",R2:R20))

HTH

Cheers
Carim



All times are GMT +1. The time now is 06:10 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com