Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I have a column like so, with each text line equalling a cell (the names are
U.S. Counties; 11 cells are below, excerpted from my dataset of around 600 rows): Mobile, Baldwin Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Talladega, Calhoun, Cleburne Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Etowah, Dekalb Mobile, Baldwin, Escambia, Conecuh, Butler, Lowndes, Montgomery, Elmore, Autauga, Chilton, Shelby, Jefferson, Blount, Cullman, Morgan, Limestone Montgomery, Macon, Lee, Chambers Mobile Tuscaloosa Jefferson Limestone, Madison Etowah I've used this formula to count all the counties in an individual cell: =IF(F7<"",LEN(F7)-LEN(SUBSTITUTE(F7,",",""))+1,0) However, now I need a state total that counts the counties in the column. Is there any way of counting only unique values so I don't double count counties when coming up with my state total? Thanks again! |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Assuming G1 contains the name of the county you want to search for and
Column F contains your listing, try this formula... =SUMPRODUCT(--ISNUMBER(SEARCH(G1,F1:F1000))) Rick "Rothman" wrote in message ... I have a column like so, with each text line equalling a cell (the names are U.S. Counties; 11 cells are below, excerpted from my dataset of around 600 rows): Mobile, Baldwin Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Talladega, Calhoun, Cleburne Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Etowah, Dekalb Mobile, Baldwin, Escambia, Conecuh, Butler, Lowndes, Montgomery, Elmore, Autauga, Chilton, Shelby, Jefferson, Blount, Cullman, Morgan, Limestone Montgomery, Macon, Lee, Chambers Mobile Tuscaloosa Jefferson Limestone, Madison Etowah I've used this formula to count all the counties in an individual cell: =IF(F7<"",LEN(F7)-LEN(SUBSTITUTE(F7,",",""))+1,0) However, now I need a state total that counts the counties in the column. Is there any way of counting only unique values so I don't double count counties when coming up with my state total? Thanks again! |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I'm sorry, but it seems once again my powers of explanation have proven to be
inadequate. I don't have a listing of counties that I'm comparing my column against. All I'm looking for is a number that represents "number of counties covered" for a particular state. Given my column, which has cells which contain more than one county, and that the same county may appear in two or more different cells, I just need to count the unique counties in the column (as opposed to summing up the formula I used to count the counties per cell, which double counts). "Rick Rothstein (MVP - VB)" wrote: Assuming G1 contains the name of the county you want to search for and Column F contains your listing, try this formula... =SUMPRODUCT(--ISNUMBER(SEARCH(G1,F1:F1000))) Rick "Rothman" wrote in message ... I have a column like so, with each text line equalling a cell (the names are U.S. Counties; 11 cells are below, excerpted from my dataset of around 600 rows): Mobile, Baldwin Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Talladega, Calhoun, Cleburne Sumter, Greene, Tuscaloosa, Jefferson, St. Clair, Etowah, Dekalb Mobile, Baldwin, Escambia, Conecuh, Butler, Lowndes, Montgomery, Elmore, Autauga, Chilton, Shelby, Jefferson, Blount, Cullman, Morgan, Limestone Montgomery, Macon, Lee, Chambers Mobile Tuscaloosa Jefferson Limestone, Madison Etowah I've used this formula to count all the counties in an individual cell: =IF(F7<"",LEN(F7)-LEN(SUBSTITUTE(F7,",",""))+1,0) However, now I need a state total that counts the counties in the column. Is there any way of counting only unique values so I don't double count counties when coming up with my state total? Thanks again! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Counting on two separate values | Excel Worksheet Functions | |||
counting the # of unique values | Excel Worksheet Functions | |||
Counting unique values | Excel Discussion (Misc queries) | |||
Counting Unique Values | Excel Worksheet Functions | |||
Counting unique entries in column A but only if specific values appear in columns B and C | Excel Worksheet Functions |