+ Reply to Thread
Results 1 to 6 of 6

count non blank cells with criteria

  1. #1
    UT
    Guest

    count non blank cells with criteria

    I need to count non blank cells that match a condition.

    For example i want to count number of entries in Column "B" for "ANTH 328"
    course.

    A B
    ANTH 328 PC
    ANTH 328
    ANTH 328 PC

    I have tried DCOUNTA and combination of functions. Nothing is working. Help
    will be greatly appreciated.

  2. #2
    Biff
    Guest

    Re: count non blank cells with criteria

    Hi!

    Try this:

    =SUMPRODUCT(--(A1:A20="ANTH 328"),--(B1:B20<>""))

    Biff

    "UT" <[email protected]> wrote in message
    news:[email protected]...
    >I need to count non blank cells that match a condition.
    >
    > For example i want to count number of entries in Column "B" for "ANTH
    > 328"
    > course.
    >
    > A B
    > ANTH 328 PC
    > ANTH 328
    > ANTH 328 PC
    >
    > I have tried DCOUNTA and combination of functions. Nothing is working.
    > Help
    > will be greatly appreciated.




  3. #3
    UT
    Guest

    Re: count non blank cells with criteria

    Hi Biff,

    The function dosent work. It counts the number of entries in Column A . So
    it gives me count of 3 in the example below. But it should actually show the
    count of 2 since there are only two entries that match "ANTH 328". Any other
    guesses?

    "Biff" wrote:

    > Hi!
    >
    > Try this:
    >
    > =SUMPRODUCT(--(A1:A20="ANTH 328"),--(B1:B20<>""))
    >
    > Biff
    >
    > "UT" <[email protected]> wrote in message
    > news:[email protected]...
    > >I need to count non blank cells that match a condition.
    > >
    > > For example i want to count number of entries in Column "B" for "ANTH
    > > 328"
    > > course.
    > >
    > > A B
    > > ANTH 328 PC
    > > ANTH 328
    > > ANTH 328 PC
    > >
    > > I have tried DCOUNTA and combination of functions. Nothing is working.
    > > Help
    > > will be greatly appreciated.

    >
    >
    >


  4. #4
    Biff
    Guest

    Re: count non blank cells with criteria

    Hi!

    Take a look at this screencap:

    http://img526.imageshack.us/img526/1241/sump0mi.jpg

    If you're getting a result of 3 based on your example then the "blank" cell
    is not blank. Is there a formula in the second column? There may be unseen
    characters like spaces.

    As you can see in the screencap the formula does return the correct result.

    Biff

    "UT" <[email protected]> wrote in message
    news:[email protected]...
    > Hi Biff,
    >
    > The function dosent work. It counts the number of entries in Column A . So
    > it gives me count of 3 in the example below. But it should actually show
    > the
    > count of 2 since there are only two entries that match "ANTH 328". Any
    > other
    > guesses?
    >
    > "Biff" wrote:
    >
    >> Hi!
    >>
    >> Try this:
    >>
    >> =SUMPRODUCT(--(A1:A20="ANTH 328"),--(B1:B20<>""))
    >>
    >> Biff
    >>
    >> "UT" <[email protected]> wrote in message
    >> news:[email protected]...
    >> >I need to count non blank cells that match a condition.
    >> >
    >> > For example i want to count number of entries in Column "B" for "ANTH
    >> > 328"
    >> > course.
    >> >
    >> > A B
    >> > ANTH 328 PC
    >> > ANTH 328
    >> > ANTH 328 PC
    >> >
    >> > I have tried DCOUNTA and combination of functions. Nothing is working.
    >> > Help
    >> > will be greatly appreciated.

    >>
    >>
    >>




  5. #5
    UT
    Guest

    Re: count non blank cells with criteria

    Hi Biff,

    The formula worked. Thanks a lot.

    "Biff" wrote:

    > Hi!
    >
    > Take a look at this screencap:
    >
    > http://img526.imageshack.us/img526/1241/sump0mi.jpg
    >
    > If you're getting a result of 3 based on your example then the "blank" cell
    > is not blank. Is there a formula in the second column? There may be unseen
    > characters like spaces.
    >
    > As you can see in the screencap the formula does return the correct result.
    >
    > Biff
    >
    > "UT" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hi Biff,
    > >
    > > The function dosent work. It counts the number of entries in Column A . So
    > > it gives me count of 3 in the example below. But it should actually show
    > > the
    > > count of 2 since there are only two entries that match "ANTH 328". Any
    > > other
    > > guesses?
    > >
    > > "Biff" wrote:
    > >
    > >> Hi!
    > >>
    > >> Try this:
    > >>
    > >> =SUMPRODUCT(--(A1:A20="ANTH 328"),--(B1:B20<>""))
    > >>
    > >> Biff
    > >>
    > >> "UT" <[email protected]> wrote in message
    > >> news:[email protected]...
    > >> >I need to count non blank cells that match a condition.
    > >> >
    > >> > For example i want to count number of entries in Column "B" for "ANTH
    > >> > 328"
    > >> > course.
    > >> >
    > >> > A B
    > >> > ANTH 328 PC
    > >> > ANTH 328
    > >> > ANTH 328 PC
    > >> >
    > >> > I have tried DCOUNTA and combination of functions. Nothing is working.
    > >> > Help
    > >> > will be greatly appreciated.
    > >>
    > >>
    > >>

    >
    >
    >


  6. #6
    Biff
    Guest

    Re: count non blank cells with criteria

    You're welcome. Thanks for the feedback!

    Biff

    "UT" <[email protected]> wrote in message
    news:[email protected]...
    > Hi Biff,
    >
    > The formula worked. Thanks a lot.
    >
    > "Biff" wrote:
    >
    >> Hi!
    >>
    >> Take a look at this screencap:
    >>
    >> http://img526.imageshack.us/img526/1241/sump0mi.jpg
    >>
    >> If you're getting a result of 3 based on your example then the "blank"
    >> cell
    >> is not blank. Is there a formula in the second column? There may be
    >> unseen
    >> characters like spaces.
    >>
    >> As you can see in the screencap the formula does return the correct
    >> result.
    >>
    >> Biff
    >>
    >> "UT" <[email protected]> wrote in message
    >> news:[email protected]...
    >> > Hi Biff,
    >> >
    >> > The function dosent work. It counts the number of entries in Column A .
    >> > So
    >> > it gives me count of 3 in the example below. But it should actually
    >> > show
    >> > the
    >> > count of 2 since there are only two entries that match "ANTH 328". Any
    >> > other
    >> > guesses?
    >> >
    >> > "Biff" wrote:
    >> >
    >> >> Hi!
    >> >>
    >> >> Try this:
    >> >>
    >> >> =SUMPRODUCT(--(A1:A20="ANTH 328"),--(B1:B20<>""))
    >> >>
    >> >> Biff
    >> >>
    >> >> "UT" <[email protected]> wrote in message
    >> >> news:[email protected]...
    >> >> >I need to count non blank cells that match a condition.
    >> >> >
    >> >> > For example i want to count number of entries in Column "B" for
    >> >> > "ANTH
    >> >> > 328"
    >> >> > course.
    >> >> >
    >> >> > A B
    >> >> > ANTH 328 PC
    >> >> > ANTH 328
    >> >> > ANTH 328 PC
    >> >> >
    >> >> > I have tried DCOUNTA and combination of functions. Nothing is
    >> >> > working.
    >> >> > Help
    >> >> > will be greatly appreciated.
    >> >>
    >> >>
    >> >>

    >>
    >>
    >>




+ 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