+ Reply to Thread
Results 1 to 4 of 4

vlookup / sumif

  1. #1
    Registered User
    Join Date
    02-28-2013
    Location
    Ireland
    MS-Off Ver
    Excel 2003
    Posts
    25

    vlookup / sumif

    I am trying to write a formula in excel.

    Sheet A col A = identifier
    Sheet B col A = identifier
    Sheet B col B = year (1,2,3 etc.)
    Shett B col C = salary

    On Sheet A col B

    I want to get the sum of salary in Sheet B col C that matches the identifier in Sheet A col A, but only for years marked as 1.


    Can anyone help?

  2. #2
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: vlookup / sumif

    Assuming that your data start in A1, try this in B1 and copy down.

    =SUMPRODUCT((Sheet2!$A$1:$A$100=A1)*(Sheet2!$B$1:$B$100=1)*(Sheet2!$C$1:$C$100))
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  3. #3
    Registered User
    Join Date
    02-28-2013
    Location
    Ireland
    MS-Off Ver
    Excel 2003
    Posts
    25

    Re: vlookup / sumif

    Thank you for this.. this returns a 0. ( better than an errror though

  4. #4
    Forum Expert Kevin UK's Avatar
    Join Date
    12-07-2010
    Location
    Radstock, Somerset
    MS-Off Ver
    365
    Posts
    1,922

    Re: vlookup / sumif

    Hi Knocknaboula

    Try the sumproduct below.

    =SUMPRODUCT(('Sheet A'!A:A="identifier")*('Sheet B'!A:A="identifier")*('Sheet B'!B:B=1)*('Sheet B'!C:C))
    Last edited by Kevin UK; 03-06-2013 at 07:47 AM.
    Regards Kevin


    Merged Cells (They are the work of the devil!!!)

+ 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