+ Reply to Thread
Results 1 to 3 of 3

If Statement Criteria

  1. #1
    Brent E
    Guest

    If Statement Criteria

    Good afternoon,

    I am trying to assist somebody at work. I would like to ask if there is a
    way to set a formula in a totals cell at the bottom or a spreadsheet (for
    example) where for every cell in
    Column A that contains a certain ID, their corresponding values in column B
    are summed. For instance if A2 A3 AND A11 contain a specific ID, then a
    'totals' cell would add B2, B3 AND B11. I would like to use an IF statement
    or something for example: (SUM B cells where A cells=ID). What syntax would I
    use for this? Thanks.


  2. #2
    Michael
    Guest

    RE: If Statement Criteria

    Hi Brent

    =SUMPRODUCT((A1:A100="ID")*(B1:B100))
    Adjust the ranges to suit and change the "ID" to whatever criteria you are
    seeking.

    HTH
    Michael
    --
    Michael Mitchelson


    "Brent E" wrote:

    > Good afternoon,
    >
    > I am trying to assist somebody at work. I would like to ask if there is a
    > way to set a formula in a totals cell at the bottom or a spreadsheet (for
    > example) where for every cell in
    > Column A that contains a certain ID, their corresponding values in column B
    > are summed. For instance if A2 A3 AND A11 contain a specific ID, then a
    > 'totals' cell would add B2, B3 AND B11. I would like to use an IF statement
    > or something for example: (SUM B cells where A cells=ID). What syntax would I
    > use for this? Thanks.
    >


  3. #3
    Biff
    Guest

    Re: If Statement Criteria

    Hi!

    Try this:

    =SUMIF(A2:A50,"ID",B2:B50)

    If your "ID" value is TEXT enclose it within quotes as I did in the formula.
    If the "ID" value is numeric, don't use the quotes.

    Biff

    "Brent E" <[email protected]> wrote in message
    news:[email protected]...
    > Good afternoon,
    >
    > I am trying to assist somebody at work. I would like to ask if there is a
    > way to set a formula in a totals cell at the bottom or a spreadsheet (for
    > example) where for every cell in
    > Column A that contains a certain ID, their corresponding values in column
    > B
    > are summed. For instance if A2 A3 AND A11 contain a specific ID, then a
    > 'totals' cell would add B2, B3 AND B11. I would like to use an IF
    > statement
    > or something for example: (SUM B cells where A cells=ID). What syntax
    > would I
    > use for this? Thanks.
    >




+ 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