+ Reply to Thread
Results 1 to 5 of 5

Create sumif

  1. #1
    Registered User
    Join Date
    01-23-2008
    Posts
    4

    Create sumif

    I am creating a workbook with many lookups and functions but i am currently stuck.

    I have 7 sumif functions looking up data from a table the first 5 work as designed but for some reason the last 2 are not working although the cell formats are the same as the other.

    Any advice?

  2. #2
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,699
    It always helps if you post a sample formula and explain, if necessary, the layout of your data and briefly, perhaps with a small example, what results you expected and what results you got.

  3. #3
    Registered User
    Join Date
    01-23-2008
    Posts
    4

    Question i have included an example

    I have attached a copy of what it looks like in word format.

    On the excel sheet I am using columns B, C, D, E, G and H with the following sum =SUMIF( ,(A3),)
    A = Name
    B = Matches - =SUMIF(I:I,(A3),L:L)
    C = Innings - =SUMIF(I:I,(A3),N:N)
    D = N/O - =SUMIF(I:I,(A3),K:K)
    E = Runs - =SUMIF(I:I,(A3),J:J)
    F = Average
    G = F - =SUMIF(I:I,(A3),N:N)
    H = H - =SUMIF(I:I,(A3),O:O)

    The problem that i am having is with the first F and H SUMIF after the AVERAGE. They should calculate and add up so as all the other sumifs do but for some reason it just returns 0. The results i would expect are:
    G3 = 1
    G4 = 1
    H3 = 0
    H4 = 1

    Hopefully this makes sense?
    Attached Files Attached Files

  4. #4
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,699
    If columns O and N are text formatted then SUMIF will return zero.

    If column O and N values are generated by formulas can you post the formula(s)? If not then try converting to numeric. You can't do that by just changing cell format. Try this

    Select column N and use Data > Text to Columns > Finish, repeat for column O

    Alternatively try this formula without converting

    =SUMPRODUCT((I$2:I$100=A3)*(N$2:N$100))

  5. #5
    Registered User
    Join Date
    01-23-2008
    Posts
    4

    thanks

    Thanks for your help on this.

    I have been able to work this out, where i was doing the the calculation on the looked up cell prior to the sumif command i was using an if function and had my numbers in " " which a friend has just pointed out will return it as text as opposed to numbers which is why the sumif would not work.

+ 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