I have a data like below in the excel from A1 to F3
Task Mon Tue Wed Thu Friday
Row 1: A 2 2 2 2 2
Row 2: B 2 2 2 2 2
I wanted to add all the values which is under row which matches "A". I am using below formula but it is not showing correct count.
=SUMIF(A1:F3,"A",B2:F3)
which is giving wrong sum.
Can you please help me in this.
Try SUMPRODUCT:
=SUMPRODUCT(($A$2:$A$3="A")*$B$2:$F$3)
Related
0
A
B
C
1
Year
From
1974
2
2004
To
2005
3
2016
Result
3
4
1996
5
6
no info
7
1974
8
no info
9
10
11
12
In Cell C3 I want to count the rows in Column A where the year is
a) >= the value in Cell C1 AND
b) <= the value in Cell C2
Therefore, I implemented this formula:
=ROWS(FILTER($A$2:$A$12,($A$2:$A$12>=C1))*($A$2:$A$12<=C2))
However, this formula returns 11 as result which is probably caused by the empty cells and the no info input in Column A.
To avoid that those inputs are considered in the count of the rows I tried to go with this:
=ROWS(FILTER($A$2:$A$12,($A$2:$A$12>=C1))*($A$2:$A$12<=C2)*($A$2:$A$12<>"")*($A$2:$A$12<>"no info"))
However, this formula still returns 11 as result.
How do I have to modify it to get the correct values?
What about COUNTIFS()? Try-
=COUNTIFS(A:A,">="&C1,A:A,"<="&C2)
and with FILTER() try-
=ROWS(FILTER($A$2:$A$12,($A$2:$A$12>=C1)*($A$2:$A$12<=C2)))
You've put double close brackets )) too early in your formula, ending the Filter() function and then putting additional conditions outside of it.
Change the formula to
=ROWS(FILTER($A$2:$A$12,($A$2:$A$12>=C1)*($A$2:$A$12<=C2)*($A$2:$A$12<>"")*($A$2:$A$12<>"no info")))
How to work following things in excel
I have
Column
A. B. C. D
12/12/17. 12. Dec. 17
13/12/17. 13. Dec 17
From column A how to extract date and month and year as shown in column B,C,D?
if any of them entering 3rd and 4 th row on their own, for row 3 and 4 column B,C,D needs to be updated automatically.
Row 3 column A is 14/12/17
Row 4 column A is 15/12/17
Note : not to use fill option in column B,C,D
Day
=Day(A1)
Month
=TEXT(A1,"ddd")
Year:
=--TEXT(A1,"yy")
I have a dashboard I'm trying to put together and I don't understand how Excel is interpreting my formulas. I'm trying to get excel to read a cell that contains a month value, and if that value is true, then to read my dummy variables and count them. There is multiple criteria here so I used CountIFS.
Here's how the function works
=IF('Other tab'!$AI:$AI=B3,COUNTIFS('Other tab'!$BI:$BI,1,'Other Tab'!$BB:$BB,1,'Other tab'!$BC:$BC,1),"ERROR")
where any place there is a "1" there was a dummy variable created. I also tried to do this with the actual text that the dummy variables replaced and my formula still wouldn't work. I don't get an error, but the return value is "0"
Here's a sample of the data:
Current Tab:
1 A B C D E F G H
2
3 Metric January February March April May June July
Other tab:
AI BB BC BI
1 January 0 1 1
2 January 0 1 1
3 January 0 0 0
4 January 1 1 1
5 January 1 1 1
6 December 1 1 1
According to my formula, "3" should be the result here.
Update: I switched the formula to read the "0"'s on my dummy variables instead of the "1"'s and it worked to retrieve that, so why isn't it working when specifying "1" as my countif criteria?
There is no reason to put the first part in an IF statement just add it as criteria to the COUNTIFS:
=COUNTIFS('Other tab'!$AI:$AI,B3,'Other tab'!$BI:$BI,1,'Other Tab'!$BB:$BB,1,'Other tab'!$BC:$BC,1)
It appears that your data not consistent. You are looking for a text string in a series of dates that is formatted mmmm. To deal with this, in another column on the Other tab put this formula:
=TEXT(AI1,"mmmm")
And copy down.
Then change the 'Other tab'!$AI:$AI part in the above formula to new column in which you just put the 2nd formula.
This will now allow the comparison of text to text.
I have 2 sheets called sheet1 and the other sheet2.
Info found on sheet1
Using columns a-d
Date Product qty used actual qty used
1-jan-16 aaaa 102 50
8-jan-16 aaaa 102 150
Date = 1 jan + 8 day till dec 31
sheet2 info
using columns a-d
Month count average
Jan
Feb
Mar
The count columns uses the =count function works OK.
But the average gives an error.
This is what I'm trying to do is average out the actual column on sheet 1 using the month criteria on sheet2, so for the month Jan it looks at sheet1 and averages out the 4 week that have the month Jan found in it.
I get #DIV/0! error
=AVERAGEIFS('sheet1'!H157:H208,'sheet1'!B157:B208,">="&Sheet2!A4,'sheet1'!B157:B208,"<="&EOMONTH(Sheet2!A4,0))
If any info missing please feel free to ask.
Thanks
For some reason it doesn't AVERAGEIFS does not like cell referencing against date values (at least for multiple conditions).
Provided that the Months are entered as actual month values formatted as mmm (which I assume based on the formula you provided), this formula works (I tested it against your sample data (extrapolated)):
=AVERAGEIFS('sheet1'!H157:H208,'sheet1'!B157:B208,">="&Date(YEAR(A4),MONTH(A4),1),'sheet1'!B157:B208,"<"&DATE(YEAR(A4),MONTH(A4)+1,1))
Friend.
I have sheet1 like below
Jan Feb Mar Apr
A 10 15 13 10
B 11 11 15 12
C 12 13 15 14
D 12 10 10 15
In Sheet 2! i have 2 scroll scroll down list in cells made by data validation.fist one is in A1 with the values A, B and C, in A2 cell with the values Jan,Feb,Mar.
What i need on this, if i select A and Jan from scroll down list. i need to show the value as '10' in A3 Cell
I tried VLook up with my limited knowlege but i can provide only one value in Lookup value and array.
Please help.
You have to provide vlookup a number of column to return as variable, which you may get as a return value of match function.
Sheet1 has populated range A1:E5, where first row contains names of months (range A1:E1). Sheet2 has only values in two cells A1 and A2.
You need to find in which column of Sheet1 is a month, that is done by
match(a2, Sheet1!A1:E1, 0)+1
and find the value with VLOOKUP.
The final formula would be
=vlookup(a1, sheet1!a1:e10, match(a2, sheet1!A1:e1, 0)+1, false)
EDIT: The first time I messed Sheet1 and Sheet2.