+ Reply to Thread
Results 1 to 9 of 9

SUMIF shows wrong value

  1. #1
    Registered User
    Join Date
    11-29-2012
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    3

    Exclamation SUMIF shows wrong value

    Hi,

    Ive been facing a problem with SUMIF, it works in one sheet but it doesnt work in sheet2.
    In the first sheet i use SUMIF to match against the Membernumer, then i take the value from the N colume and add it to sheet 5.
    =SUMMA.OM(Medlemsregister!A2:A700;"519";Medlemsregister!N2:N700)
    http://imgur.com/Ky4GW

    That is working great. But when i try to do the same thing to this sheet. I want to search throght column H to search for the membernumber. If i found it i want to get the Value from column E in the same row and copy that to sheet 5.
    =SUMMA.OM(Blad5!H2:H700;"=38";Blad5!E2:E3)
    http://imgur.com/rOySR

    When it should be the value 2 i get 4, and when it should be the value 1 i get 5. Strange logic. Please help.

    Im from sweden and thats because my grammar is bad.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,451

    Re: SUMIF shows wrong value

    Can't open you examples - Why do you comapre to a string ? "=38". Is =SUMMA.OM(Blad5!H2:H700;38;Blad5!E2:E3) not what you need?

  3. #3
    Forum Contributor dogberry's Avatar
    Join Date
    07-15-2012
    Location
    Wales, UK
    MS-Off Ver
    Excel 2010
    Posts
    624

    Re: SUMIF shows wrong value

    Hi

    Sorry but we cant edit a picture if you would like to upload a sample worksheet Im sure someone will help you out.


    Chris
    Click my star if I helped Thanks

  4. #4
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: SUMIF shows wrong value

    Hi psykfall123,

    Welcome to the forum.

    In a first glimpse, I can see that the range in second formula is not correct.. try with Blad5!E2:E700. thanks.

    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), [email protected]

  5. #5
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: SUMIF shows wrong value

    Hi psykfall123,

    Welcome to the forum.

    In a first glimpse, I can see that the range in second formula is not correct.. try with Blad5!E2:E700. thanks.

    Regards,
    DILIPandey

    <click on below 'star' if this helps>

  6. #6
    Registered User
    Join Date
    11-29-2012
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: SUMIF shows wrong value

    Accually i tried with E700 also. It doesnt work. I get some strange values all the time. But it works with the first code. I cant see any logic in my problem.

  7. #7
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: SUMIF shows wrong value

    An oddity of the SUMIF function is that the 3rd argument (Blad5!E2:E3) automatically expands to reference a range of the same size as the 1st argument, without changing the display of that reference.
    Consequently, even though you entered: =SUMMA.OM(Blad5!H2:H700;"=38";Blad5!E2:E3)
    Excel intereprets it as: =SUMMA.OM(Blad5!H2:H700;"=38";Blad5!E2:E700)

    Does that help?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  8. #8
    Registered User
    Join Date
    11-29-2012
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: SUMIF shows wrong value

    I have changed the code now to =SUMMA.OM(Månad!H2:H700;519;Månad!E2:E700) and i have renamed Sheet5 to "Månad". But it still doesnt work. The number 38 and 519 are different membernumers and it gives strange numbers all the time.

  9. #9
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: SUMIF shows wrong value

    I think you'll need to post some sample data that exhibits the problem.

+ 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