|
|
||||||
|
#1
|
|
|
|
|
=SUMIF(Rewards!$AH$3:$BI$3,Targets!O30, Rewards!$AH$20:$BI$20)
=SUMIF(Rewards!$AH$3:$BI$3,Targets!O30, Rewards!$AH$20:$BI$20) In the above equation I am trying to get a total using sumif. The rewards cells row 3 refer to a range of automatically generate consecutive date cells. The target cell is a manually entered date The reward cells in row 20 are automatically generated numbers. What I am trying to do is have the calculation check for the date i Targets and then only sum the numbers that are entered on dates equa or after that entered in targets I also tried =SUMIF(Rewards!$AH$3:$BI$3, ">Targets!O30:<O31" Rewards!$AH$20:$BI$20) in the hope of getting it to sum between two given dates. Any clues out there? I'm going around in circles here |
|
|
|
#2
|
|
|
|
|
This one always gets me and I can never remember how to do it, so I had a
friend write up this article, Dond: http://www.officearticles.com/excel/...soft_excel.htm ************ Anne Troy www.OfficeArticles.com "dond" <dond.1y7p3a_1131510001.2081> wrote in message news:2081 [..] |
|
#3
|
|
|
|
|
Hi everyone,
Could anyone help!!! I would like to know if I could use SUMIF function with two criteri and two ranges in it. For example, I would like to sum up a columb i any given cell in that columb fulfills two criteria. The one criteri is in one columb, the other criteria is in other columb. Thank you |
|
#4
|
|
|
|
|
Not =sumif().
But you can use =sumproduct() =sumproduct(--(a1:a10="something"),--(b1:b10="another"),c1:c10) =sumproduct() likes to work with numbers. The -- converts true/falses to 1/0's. Extend your range to what you want, but don't use the whole column. kras wrote: [..] |
|
#5
|
|
|
|
|
Hi Dave,
Thank you for your reply. The problem is that one of the columbs contains letters, not numbers and sumproduct formula returns #VALUE! Probably I have to be more specific. I'll give you an example. So, there are three columbs in my spreadsheet. The first contains time in which a process starts /for ex. 11:24:32/. The second columb contains the duration of the process /for ex. 00:03:45/. The third columb contains the kind of process/ for example SB, SS, etc./. I would like to find out the average time duration of a given process /lets say SB/ after 15:30:00. |
|
#6
|
|
|
|
|
This formula:
=sumproduct(--(a1:a10="something"),--(b1:b10="another"),c1:c10) expects to find numbers in C1:C10. If you have text/errors in that range, then you'll have trouble. (You'd have to adjust the ranges to match your data.) But from what you wrote in your followup, you're only looking at one criteria. So maybe something like: =SUMIF(C1:C10,"SB",B1:B10)/COUNTIF(C1:C10,"SB") Oopsie.... You wanted it after 15:30:00, so back to =sumproduct() =sumproduct(--(a1:a10>=time(15,30,0)),--(c1:c10="sb"),b1:b10) / sumproduct(--(a1:a10>=time(15,30,0)),--(c1:c10="sb")) All one cell. That assumes that the times in column A are really times--they don't include dates. (Sum up all the duration times in column B that matches the criteria and divide it by the count that match both criteria.) kras wrote: [..] |
|
#7
|
|
|
|
|
Hi Anne,
Really appreciate the assistance. I would never have got tha calculation and it is a very useful tip to file away for late reference. This completed the last part of a project I have bee working on for months. Once again thankyou for the help. Don |
|
#8
|
|
|
|
|
Hi Dave,
Thank you again for your prompt answer. I tried the formula you wrote down in your last post. The problem is that as soon as i write a condition such as >=time(15;30;0) or ="sb" in the formula, it returns 0. If I remove conditions from the formula it returns a result. Also, I looked at formula help menu. It is said there that if one of the arrays are not numeric the formula considers them as zeros. I think this is an additional problem for using this formula, because one of arrays are letter /ex. SB/. Do you think I could use another formula, instead of SUMPRODUCT? In my case, lets say, I need two levels of data filtering. The first level is to filter data by the condition "SB", and the second level is to filter the already filtered data by the condition "time". After that I have to find the average minutes a process lasts after a specific time, say 15:30:00. For example: Time In duration process 10:23:12 2:45 SB 10:45:05 1:12 AA 10:56:25 0:56 SB 15:45:14 5:23 SB What if I use IF functions? Can I manage this in one cell? Best regards, kras Dave Peterson Wrote: [..] |
|
#9
|
|
|
|
|
Change the formula to look at just one row that should work ok.
Now look at the values in the cell (leading/trailing spaces in the SB column) or dates/times in the time column. In fact, make sure that the time entered is really a time. Format that cell as general and what do you see. It sould be a decimal number between 0 and 1. If that doesn't work, then post the single row of data and the current formula you're trying. kras wrote: [..] |
|
#10
|
|
|
|
|
Hi Dave,
I didn't manage to do it. I attached an excel file with the exampl table and the formula you provided +------------------------------------------------------------------- |Filename: Book1.zip |Download: http://www.excelforum.com/attachment.php?postid=4036 +------------------------------------------------------------------- |
|
#11
|
|
|
|
|
I don't connect through excelforum--so I can't see the attachments.
But I'm one of those people who won't open attachments. Maybe someone else will open it and jump in with an answer--or you can post in plain text. kras wrote: [..] |
|
#12
|
|
|
|
|
Sure Dave,
I'm posting a plain text below: ColumbA/ColumbB/ColumbC/ColumbD Time In Time out Duration Process 10:43:36 10:45:49 02:13 SB 10:50:34 10:50:52 00:18 BB 15:40:44 15:43:08 02:24 SB 15:48:25 15:49:00 00:35 SB 11:27:00 11:28:14 01:14 BB Single row formula: =SUMPRODUCT((A4>=TIME(15;30;0));(D4="SB");C4). didn't divided it to SUMPRODUCT((A4>=TIME(15;30;0));(D4="SB") purposely and saw that it returns #VALUE! Single row formula =SUMPRODUCT((A4>=TIME(15;30;0));(D4="SB");C4)/SUMPRODUCT((A4>=TIME(15;30;0));(D4="SB")) It returns #VALUE! The Time In and Time Out cells are set to: hh:mm:ss. The Duration cells are set to: mm:ss The Process cell is set to: general Formula cell is set to: genera |
|
#13
|
|
|
|
|
You seem to have dropped some double negative signs.
This worked with my USA settings (comma vs. semicolon) =SUMPRODUCT(--(A4:A99>=TIME(15,30,0)),--(D4:D99="SB"),C4:C99) /SUMPRODUCT(--(A4:A99>=TIME(15,30,0)),--(D4:D99="SB")) Watchout for typos: =SUMPRODUCT(--(A4:A99>=TIME(15;30;0));--(D4:D99="SB");C4:C99) /SUMPRODUCT(--(A4:A99>=TIME(15;30;0));--(D4:D99="SB")) =sumproduct() likes to work with numbers. The -- stuff converts true and false to 1 and 0. kras wrote: [..] |
|
#14
|
|
|
|
|
Hi Dave,
Wow!!! It works now. Thank you very much for your precious help. really appreciate it. After using this formula it saved me a lot of redundant columbs. Best regards, kra |
|
|
| Similar Threads | |
| Customer Rewards Tracking I need some help. I have been asked to look into (for Dynamics GP) the availability of a rewards program. A GP customer would like to offer their clients a program where... |
|
| Which credit card gives the best rewards ? Which credit card gives the best rewards ? I have had a Capital One (US) visa card for many years. I always pay my visa bill on time. I am fed up of them. In the last 2... |
|
| Customer Rewards Add On Is anyone aware of an RMS add on that would generate customer rewards? What I would like it to do is for every $250 a customer spends, our system would automatically print a... |
|
| Setup for Gas Card Rewards I haven't seen this covered, but can money track rewards from credit cards other then sky miles? Can it track cash back on gas cards? Thanks T |
|
|
All times are GMT. The time now is 03:30 PM. | Privacy Policy
|