ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Excel Lookup help (https://www.excelbanter.com/excel-discussion-misc-queries/195551-excel-lookup-help.html)

B_vegas

Excel Lookup help
 
I am trying to figure out how to do the following. I am trying to get a sum
of numbers in a column, but the numbers need to fit certain criteria. For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and "and"
statement, but i'm not sure how to word this. Could someone Please help!

RagDyeR

Excel Lookup help
 
Couple of ways:

=Sumif(A1:A500,"=40")-Sumif(A1:A500,"60")

OR

=Sumproduct((A1:A500=40)*(A1:A500<=60)*A1:A500)
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"B_vegas" wrote in message
...
I am trying to figure out how to do the following. I am trying to get a

sum
of numbers in a column, but the numbers need to fit certain criteria. For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and

"and"
statement, but i'm not sure how to word this. Could someone Please help!



B_vegas[_2_]

Excel Lookup help
 
Thank you very much!

"Ragdyer" wrote:

Couple of ways:

=Sumif(A1:A500,"=40")-Sumif(A1:A500,"60")

OR

=Sumproduct((A1:A500=40)*(A1:A500<=60)*A1:A500)
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"B_vegas" wrote in message
...
I am trying to figure out how to do the following. I am trying to get a

sum
of numbers in a column, but the numbers need to fit certain criteria. For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and

"and"
statement, but i'm not sure how to word this. Could someone Please help!




joromajr

Excel Lookup help
 

-- What if the scenario were the Criteria was in column 1 let us say account
name then the amount was in column 5 and you needed to add all for a
particular account name?

joromajr


"Ragdyer" wrote:

Couple of ways:

=Sumif(A1:A500,"=40")-Sumif(A1:A500,"60")

OR

=Sumproduct((A1:A500=40)*(A1:A500<=60)*A1:A500)
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"B_vegas" wrote in message
...
I am trying to figure out how to do the following. I am trying to get a

sum
of numbers in a column, but the numbers need to fit certain criteria. For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and

"and"
statement, but i'm not sure how to word this. Could someone Please help!




RagDyeR

Excel Lookup help
 
You could choose from either of the same 2 functions:

=Sumif(A1:A500,"Acctname",E1:E500)

Or

=Sumproduct((A1:A500="Acctname")*E1:E500)

--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------

"joromajr" wrote in message
...

-- What if the scenario were the Criteria was in column 1 let us say

account
name then the amount was in column 5 and you needed to add all for a
particular account name?

joromajr


"Ragdyer" wrote:

Couple of ways:

=Sumif(A1:A500,"=40")-Sumif(A1:A500,"60")

OR

=Sumproduct((A1:A500=40)*(A1:A500<=60)*A1:A500)
--
HTH,

RD


--------------------------------------------------------------------------

-
Please keep all correspondence within the NewsGroup, so all may benefit

!

--------------------------------------------------------------------------

-
"B_vegas" wrote in message
...
I am trying to figure out how to do the following. I am trying to get

a
sum
of numbers in a column, but the numbers need to fit certain criteria.

For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and

"and"
statement, but i'm not sure how to word this. Could someone Please

help!




RagDyeR

Excel Lookup help
 
You're welcome, and appreciate the feed-back.
--
Regards,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"B_vegas" wrote in message
...
Thank you very much!

"Ragdyer" wrote:

Couple of ways:

=Sumif(A1:A500,"=40")-Sumif(A1:A500,"60")

OR

=Sumproduct((A1:A500=40)*(A1:A500<=60)*A1:A500)
--
HTH,

RD


--------------------------------------------------------------------------

-
Please keep all correspondence within the NewsGroup, so all may benefit

!

--------------------------------------------------------------------------

-
"B_vegas" wrote in message
...
I am trying to figure out how to do the following. I am trying to get

a
sum
of numbers in a column, but the numbers need to fit certain criteria.

For
example;

I have 500 numbers in a column ranging from 1 to 130
I need the sum of only the numbers between 40 and 60.

I figure that this involves the sum function and some type of "if" and

"and"
statement, but i'm not sure how to word this. Could someone Please

help!





All times are GMT +1. The time now is 08:58 AM.

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