# Count Multiple Values In Cell With Range Criteria

Apr 30, 2009

I'm trying to figure out how to count by two criteria, only one of the criteria has a value among multiple values in a cell and the other is a range. I tried to use sum but it doesn't count the value and count doesn't recognize the range. I attached the file so you can see what we're trying to do.

## Count Rows Meeting Multiple Criteria Of Multiple Values

Aug 10, 2009

I am trying to find a formula to count rows that meet multiple criteria, but one of the criteria can be multiple values. I have a list of people with a list of clients that they are responsible for. Each person is responsible for 10-20 clients. Every day I run a report that shows the project worksheets submitted for each client and if money has been awarded or not.

I'm wondering if there is a way to count, for each person, the number of project worksheets that show "awarded" in column K. That would mean that I would have to look for, for each person, any of their multiple clients in column B and "awarded" in column K.

I am trying to put the formula in D2:D9, as I use A2:D9 for a chart. O1:P79 contain the names of the people and the applicants that they are responsible for. A17:D158 contains the list of project worksheets (updated daily). I used =SUMPRODUCT(COUNTIF(B17:B999,P1:P14)) to count the actual number of project worksheets for each person, but I can't figure out a way to modify that to add in the "awarded" criteria also.

## Count Unique Values With Multiple Criteria

Oct 27, 2011

I have this formula to give me the number of unique locations and it works fine for cell J1:

=SUM(IF(FREQUENCY(MATCH(\$B\$3:\$B\$22,\$B\$3:\$B\$22,0),MATCH(\$B\$3:\$B\$22,\$B\$3:\$B\$22,0))>0,1))

What I am trying to figure out is how to populate cells N4:N5 and N8:N9 for unique locations by Fruit & Vegtables by Area A and Area B. I just have some basic data for this example as the spreadsheets are 30,000+ lines long.

## Count Unique When Multiple Criteria In One Range

May 17, 2012

I have two ranges of data and want to count the unique number of times the values in column A occur if they have two values in column B. For Example:

ColA ColB
333310143333306344441014444430635555161246666101466661612466663063

I want to count the number of times value in ColA has the value 1014 AND 3063. My intention is to create a table that cross references the two

10143063161241014331306333116124112

I searched and found answers where multi criteria were in multi columns but I can't seem to find a solution to this means of find the unique count in ColA.

## Count Unique Values With Multiple Criteria And Using Wild Cards?

Oct 18, 2012

I am looking for a formula which will allow me to count unique values in a database, based on multiple criteria. Sample file attached (Formula required in cells J and K).

## Excel 2003 :: Formula For Counting Values Across A Range Using Multiple Criteria Across Multiple Sheets

Feb 9, 2014

I have saved this on a 2010 workbook as I am at home but this will be used on a 2003 workbook.

I have several projects on one spreadsheet which multiple users will be working and I am trying to create a summary sheet of the work carried out.

Each user is expected to carry out a task on each row of the data held in each worksheet (research, call, update etc) and each task (Option 1-5) is assigned a value. Each user is expected to meet a certain level of points per day to calculate productivity.

I am looking for a sumproduct along the lines of the summary sheet attached but mine just takes one sheet into consideration and I need one for all sheets.

## Multiple Criteria And SUMPRODUCT (count The Number Of Rows That Have Values Greater Than 10/01/2008 In Either Of Two Fields)

Jan 23, 2009

I am trying to count the number of rows that have values greater than 10/01/2008 in either of two fields. I tried following formula but instead of giving total number of rows, it returns a random date.

## Count Values In One List And Then Narrow / Combine Values Based On Criteria And Count Those

Jan 20, 2014

I need a way to find a value in a column which has one or more corresponding values in an adjacent column. Then take all of the corresponding values found and count all occurrences of the found values in another column. But I only want to count the entries if an adjacent column is not blank.

Not the easiest thing to describe. Starting to wonder if I need to think in reverse. I hope the attached example makes more sense.

Book1.xlsx

## Count Unique Values If Adjacent Cell Meets Criteria

Apr 30, 2014

In the picture below, I need a formula in column E to count the unique occurrences in column A (excluding blanks) if its corresponding value in column B (B1 value) matches that in column D (B2 value). Currently column E is showing the values I would want the formula to return.

Capture.PNG

At the moment I have a formula as below:

=SUMPRODUCT(--(B:B=\$D2),--(A:A<>""))

this will do a countif in column A if column B matches the value in column D, but would not weed out duplicates for me.

Modifying my formula. I have attached the sample workbook below.

Book1.xlsx

## Multiple Options Cell Values Based On Multiple Criteria Variable Inputs?

Mar 18, 2013

I maintain the data flow at my work. We send and receive the data using excel files with specific formatting that I then upload to the database. Each time I send or receive the excel file I must log them, this is what my code question refers to.

I use RDBMerge to merge all the contents of the 100 plus excel files into one worksheet. The first part of the macro cleans up the merge data for use in the log (i have attached an example of the clean data and finished log).

The blue shaded area of the "Raw_Data" is what the clean data looks like, the yellow column is what current macro records for each record.

As you can see by the example the Raw_Data is only two files LL_LLL_BOB_ToLLLLL_20121228_01 & LL_LLL_BOB_ToLLLLL_20121230_01, each with more that one record.

The log code in column "H" Is based on this criteria:
First Letter of the Unique ID in column "E" - O, M, or L
Program Type in Column "F" - U or R
1. O-U = U
2. O-R = RU
3. M-U = U2
4. M-R = R2U
5. L-R = R

You will note that Columns G-R of the "Log Sheet" correspond to the "Record Type" found in Column "G" of the "Raw_Data" sheet.

This is the area where my skill at using scripting dictionaries fails.

The results for the log list each file only once, but the log code for each corresponding "Record Type" in columns G-R of the "Log Sheet" must contain each unique instance of the code. In other words

if LL_LLL_BOB_ToLLLLL_20121228_01 contains an O-U with an "A" Record Type and an M-R with an "A" Record Type; then, on the log sheet there needs to be the codes "U/R2U" in the cell intersection of the LL_LLL_BOB_ToLLLLL_20121228_01 record row and "A" column (which is column "G")

So, If the File contains one of each code for each Record Type the corresponding cell must house one of each code separated by a "/" without any spaces. This means the cell value could no code, or one code and all the variations in between to all five codes. Also, for ease of human reading the log codes should be concatenated in the 1-5 order that I listed them in (U/RU/U2/R2U/R)

Here is my code so far.

VB:
Option Explicit
Sub test()
Dim dic As Object, a, i As Long, rng As Range, e, w, n As Long
Set dic = CreateObject("Scripting.Dictionary")

[Code].....

## For Each Loop To Count Text In A Cell With Multiple Criteria In Single Column

Dec 19, 2011

Is there any method to speed up a for each loop to count text in a cell with multiple criterias in a single column. This is on example:

Code:
For each rr in r

If rr = "a" And rr.Font.Strikethrough = False Or rr = "B" _
And rr.Font.Strikethrough = False Then
a = a + 1

end if
next

## Search Multiple Values In A Cell With Multiple Criteria

May 22, 2009

I am trying to search for multiple values in a cell with Multiple criteria.

E.g: Please find attached the sample excel data.

I tried using VLOOKUP which is not working as I am having multiple values in column A.

## Sum By Multiple Criteria & Use Cell Values As References

Nov 19, 2009

I want a total of column F based on criteria in column D and column K from the worksheet named in cell C9. I have put in the indirect function in the first part but am messing up the syntax in the second and third part of the formula. "Indirect(C9&" should be where 'Oct2009' is shouldn't it. Where am I going wrong with the following formula?

SUMIFS(INDIRECT(C9&"!\$F\$2:\$F\$11000"),'Oct2009'!\$D\$2:\$D\$11000,\$C\$1,'Oct2009'!\$K\$2:\$K\$11000,"YOKO")

## Count Cells Depending Upon Multiple Cell Values

Aug 2, 2007

In what would be Cell E2 I want to post the Total posted set Assuming that the Order Numbers and the OP Numbers are the Same, but only if there is a value in the allowed set, So I'd expect E2 in the case below to read 1.83,

Order No OP Posted Set Allowed Set
30761157 00100.731.500
3076115700100.500.000
3076115700100.600.000
3076461000100.000.000
3076461000101.050.500
3076524400100.000.000
3076524400100.550.500
3076639600100.000.000
3076639600101.180.500
3076810900100.000.000
3076862900100.000.000
3076862900100.000.000
3076862900100.000.000

## Count The Number Of Multiple Values In A Single Cell

Jan 28, 2010

formula that will return the number of "x"s or "o"s within the same cell.

The cell has values that are formatted in multiple ways for example: PXX--XXP, --XO, OXX--.

I want the formula to return 4 if the cells has PXX--XXP or 3 if the cells has --OXX etc.

## Count In A Range If Cell Contains Time Value (skip Numeric Values)

Jun 11, 2013

I'm looking for a way to count the cells in a specified range if the cell contains a timevalue (such as: 0:05 or 1:15). When a cell in the same range contains a normal value (such as: 1 or 20) it should not be counted.

What formula should i use for this?

I was experimenting with:

=CountIF(N4:N50,">TIMEVALUE(0:01)")
and
=CountIF(N4:N50,">TIME(0,0,1)")

But both don't seem to work.

## VBA - Copy Range With Multiple Same Values Based On Other Cell Values

Aug 31, 2012

I want to build a database where the user can select a specific time period. I have a static file with the time periods and the related values. For instance I have in column A1:A15 the time periods from January 2011 to Dezember 2011, but I have some dates multiple times as there are more values attached to it. For instance I have in the first 4 rows January 2011...what I want is when someone puts in the value January 2011 in cell B1 and Dezember 2011 in cell B2 that the whole static file gets copied to another location (including the multiple dates) displaying the chosen time period. Similarly if someone puts in the value March 2011 to November 2011, I want only those values to be copied.

## Multiple Criteria Count Between 2 Dates & Other Criteria

Jul 30, 2008

I have a spreadsheet which lists letters issued, the date issued and the potcode. I need a formula that counts, on a weekly basis, the number of letters issued to postcodes in Sutton and Bexley.

I have a count sheet set up on one worksheet and the list of postcodes applicable to each area are listed on another worksheet. I have been playing around with sumif, sumproduct etc, but these don't seem to work as I am pointing the formula to a list of postcodes and not an individual postcode. For example, the formula for one week needs to tell me, the number of letters issed to Sutton between 26/07/08 - 01/08/08. This is what I tried -

=SUMPRODUCT(('MU63 NC'!\$F\$2:\$F\$10>=COUNT!B\$2)*('MU63 NC'!\$F\$2:\$F\$10<=COUNT!B\$3)*('MU63 NC'!\$D\$2:\$D\$10=Sutton!\$A\$2:\$A\$50))

But I get #N/A - if I change the last refernce to a specific cell instead of a range it works, but this will make the process very lengthy as there are lots of postcodes!

## Count If With Multiple Criteria

Jul 12, 2014

if possible, with a Excel formula. Assuming a column (M7:M200) has this information:

John
Mary
Lisa
Mark
John
Albert
|_Empty _|
|_Empty _|
|_Empty _|

I would get the sum of the cells except "empty", "John" and "Mark". The result would be: John: 2 | Mark: 1 | Others: 3 (My only interest is the formula to get the result "Others: 3") I tried with this formula: = COUNTIF (M7:M200, "<> John") but remains exclude "empty" cells and "Mark."

## Count Given Multiple Criteria?

Aug 7, 2014

In H:5 I am trying to count B:2 through B:200 if it has an x and A: through A:200 has Post put value in H:5

h.png

## Count Using Multiple Criteria ..

Aug 29, 2008

I'm struggling with a simple count problem.

Column "A" has values from 0 to 1000.
Column "B" has values from 1% to 100%

If column "A" is 250 or greater count it.

OR

If column "B" is 50% or greater count it.

## Count With Multiple Criteria

Jun 20, 2006

I need to somehow count the number of times two criteria are met in a certain set of data and store it in a cell on a seperate sheet. My data is all stored in a sheet called Data and the conditions are as follows:

1. Column C = WEB
AND
2. Column D = Cancelled

So I need to count the number of times both these events occur and save them in my other sheet called Metrics. i lokoed it up on google but all the formulas I found referenced the same sheet and wouldn't work for my data set.

## Count Unique Values With Specific Criteria

Oct 31, 2011

I have data in the following type

A Criteria B
A Criteria C Criteria A
C Criteria C
D Criteria 1
2 Criteria 3

Criteria 2
3 Criteria

I need a formula that will count the number of unique values in column A that have "Criteria" in column B. In this case the desired output would be 5 (A, C, D, 2, and 3), a blank cell in column A does not need to be counted.

## Count/Sum Unique Values Based On Criteria

Feb 19, 2009

I'm facing a big problem and I can't found a solution for days.

I'm trying to count/sum unique values in a Range, base on a criteria excluding Blank cells. Basicly I'm using the Formula Below:

=SUMPRODUCT((C2:C20"")/COUNTIF(C2:C20,C2:C20&""))

Let me Put to you an example for you been able to understand my problem.

Example considering Range "C2:C20" exluding blank cells

(1) - To count unique values
=SUMPRODUCT((C2:C20"")/COUNTIF(C2:C20,C2:C20&""))

(2) - To count unique values based on criteria in range "B2:B20"
=SUMPRODUCT((C2:C20"")/COUNTIF(C2:C20,C2:C20&"")*(B2:B20="E"))

(3) - To sum unique values on "E2:E20" based on same criteria
=SUMPRODUCT((C2:C20"")/COUNTIF(C2:C20,C2:C20&"")*(B2:B20="E")*(E2:E20))

They all work fine. But I need to insert a merge at Row 10 for
better reading purposes and the (2) and (3) are returning (#DIV/0). The (1) formula still work's.
I just don't know what to do guys ....

## Count Unique Values With Specific Criteria

Dec 3, 2007

I need to count the amount of Unique codes in column A BUT ONLY if they are still OPEN status. Hopefully the attached example will be explaination enough (I want to automate the RED figure...

## Multiple Cell Values Into A Variable - Then Place In Another Range?

May 17, 2014

how to set a cells value into a variable, using .value, then set another cells value equal to that variable without using copy/paste

What I can't figure out is how to see the value of multiple cells to a variable and place them into another range of the same size using .value. It would be nice to free up the clipboard.

## Count Occurrences Using Multiple Criteria

Feb 25, 2014

Iam doing a market report for real estate. I have attached a file for reference. I am trying to track the Active Listings within a given time period and within a specific zip code. Unfortunately my local MLS does not track historical data on Active Listings, and therefore I have to use the Listing Date and the date it no longer went active to determine which listings were active in a given time period. Some of the listings are still active and therefore do not have a "No Longer Active" date. These listings will need to be counted as well.

MLS Active by Zip.xlsx

## Count Multiple Columns And Criteria

Mar 13, 2014

What I'm trying to do count the TRUE values in multiple columns, if the criteria is correct in another column.

I've tried countifs but end up having the company included into the count, or only count the row that matches all the criteria.

If I do =COUNTIFS(A2:A7,"A",B2:B7,"TRUE")+COUNTIF(C2:C7,"TRUE") then I get 5.

When I change it to +COUNTIFS(A2:A7,"A",C2:C7,"TRUE") it works but there's a time where I need to check up to 8 Options.

Company
Option 1
Option 2

a
True
True

b
True
False

c
True
False

a
True
False

a
True
False

b
True
True

## Count According To Multiple Criteria. Dcount?

Nov 10, 2009

OK, I have a list of sales that my semester long company has sold. In the midst of these sales we are sellling a versoin of the bumble watches. people can either buy a watch, (which includes a face and a band) a face, or a band.

So I have this giant list and only like 10 watches on there. I need a formula that will count how many watches and faces we sell.

I was initially thinking something along the lines of:
=COUNT(OR('Sales Journal'!D:D="Watch",'Sales Journal'!D:D="Face"))
=COUNT(OR('Sales Journal'!D:D="Watch",'Sales Journal'!D:D="Band"))

Which worked great until I had more than one watch in there.

I can't figure out dcount, and don't know if it's even the right thing to use in this instance. If you want I can post the sales journal..

## Using Countif(s) To Count Multiple Criteria

Nov 25, 2013

I have a bunch of cells that i want to count in a table based on 2 criteria. The first would be checking whether or not it matches a certain text which i can do. Now i have a column for "Completed Date" and "Deadline Date". Each deadline date is different. I know i need some sort of array function in there to compare all the completed dates vs deadline dates but i just can't think of it. This will be the second criteria.