ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Excel IF and COUNT functions (https://www.excelbanter.com/excel-worksheet-functions/13905-excel-if-count-functions.html)

Robin Faulkner

Excel IF and COUNT functions
 
I need to write an IF statement that look in the first column for a set value
and then counts the number of repetitions in column two. Column two contains
dates which contain duplicates. The statement needs to count dupicate dates
as single entries.

Jason Morin

Try:

=SUM(N(FREQUENCY(IF(A1:A100=E1,MATCH
(B1:B100,B1:B100,0)),MATCH(B1:B100,B1:B100,0))0))

Array-entered, meaning press ctrl + shift + enter, whe

A1:A100 = 1st column
B1:B100 = 2nd column (dates)
E1 = value to look for in 1st column

HTH
Jason
Atlanta, GA



-----Original Message-----
I need to write an IF statement that look in the first

column for a set value
and then counts the number of repetitions in column

two. Column two contains
dates which contain duplicates. The statement needs to

count dupicate dates
as single entries.
.


Aladin Akyurek

=COUNT(1/FREQUENCY(IF(($B$1:$B$100<"")*($A$1:$A$100=E1),MA TCH($B$1:$B$100,$B$1:$B$100,0)),ROW(INDEX($B$1:$B$ 100,0,0))-ROW($B$1)+1))

which must be confirmed with control+shift+enter instead of just with enter.
Robin Faulkner wrote:
I need to write an IF statement that look in the first column for a set value
and then counts the number of repetitions in column two. Column two contains
dates which contain duplicates. The statement needs to count dupicate dates
as single entries.



All times are GMT +1. The time now is 12:26 PM.

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