View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jeremy Ellison
 
Posts: n/a
Default value of #'s in column if between dates

I used the circle invalid dat button and found some data in one of my columns
hat was incorrectly put in there. I then removed it and this gave me the
total of what i was looking for.

I will now try to combine my total of total 1 and total 2. feel free to
post if you have suggestions while i work on this. thank you.

"Jeremy Ellison" wrote:

Here's what I have been trying:

=SUMPRODUCT((CaseData!C2:C1000=DATE(2005,10,1))*( CaseData!C2:C1000<=DATE(200,12,31))*(CaseData!AT2: AT1000="Heroin")*CaseData!AU2:AU1000)



for the follwoing data


C AT AU
1 Date DRUG Amount
2 10/1/5 Heroin 2.2
3 1/2/6 Heroin 5.5

I get a "VALUE" error when I run this...I want it to return 2.2 because row
2 is between the dates specified.


Any one know how to get it to work correctly? I/m lost!


IF I do come up with the answer for this... I will want it to then look at 2
more columkns with the same data... Example:

C AT AU AV
AW
1 Date DRUG Amount Drug2
Amount2
2 1/1/6 Heroin 2.2 Grams Meth
2.5
3 1/2/7 Heroin 5.5 Grams MJ
1.1

The formula will need to add AU & AW together, if C is between dates and
AT=a certain drug....

THanks!