+ Reply to Thread
Results 1 to 4 of 4

COUNTIF function help!!

  1. #1
    Forum Contributor
    Join Date
    02-03-2005
    Location
    Chicago, IL
    Posts
    101

    COUNTIF function help!!



    I am having trouble with the COUNTIF Function. I am trying to use a wildcard in my criteria.

    My data is all contained in column E. It looks like this

    40400
    40400
    40420
    40430
    40500
    40600

    This is the formula I am using =COUNTIF(Sheet1!$E:$E,"404*")
    Baisclly I want the function to return the number of rows that have either 40400, 40420 or 40430 (ie. 4).

    If I change out the "404*" with 40400, it works perfectly.
    Am I missing something?

  2. #2
    Registered User
    Join Date
    02-03-2005
    Posts
    1
    I think countif will only work the way you want if you format the column you're checking as text, rather than general or number. I don't think wildcards work well with numeric data, you'd need to use operators for that (>,< etc)

    hope this helps

    Jellyarm

  3. #3
    Forum Contributor
    Join Date
    02-03-2005
    Location
    Chicago, IL
    Posts
    101
    thanks for the advice Jelly.

    Still having trouble figuring out how to define the number range in my criteria...

    (ie. ">=40400" and "<=40430")

    I must just be missing the boat. Excel doesn't seem to like anything I drop in there....

  4. #4
    Forum Expert
    Join Date
    06-18-2004
    Location
    Canada
    MS-Off Ver
    Office 2016
    Posts
    1,474
    Try the following...

    =SUMPRODUCT(--(E1:E100>=40400),--(E1:E100<=40430))

    Note that SUMPRODUCT doesn't accept whole column references.

    Hope this helps!

    Quote Originally Posted by Celt
    thanks for the advice Jelly.

    Still having trouble figuring out how to define the number range in my criteria...

    (ie. ">=40400" and "<=40430")

    I must just be missing the boat. Excel doesn't seem to like anything I drop in there....
    Last edited by Domenic; 02-03-2005 at 07:11 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1