+ Reply to Thread
Results 1 to 9 of 9

Grocery List with Price comparison

  1. #1
    Registered User
    Join Date
    04-04-2012
    Location
    South Africa
    MS-Off Ver
    2010
    Posts
    4

    Grocery List with Price comparison

    Hi all

    I'm quite out of touch with excel and need some advice.

    I want to create a simple grocery list with different ITEMS listed in column A. B2 though F2 must contain five different STORE NAMES. Prices will be filled in in B3:F20 for example. In G column I want to display the lowest price for a certain ITEM. This I can do with the MIN function. My problem is the next phase where I want to retrieve the STORE NAME with the lowest price. After that has been done I want to filter the list and basically print 5 different shopping lists to see what has to be bought from where.

    Any idea of how to retrieve the STORE NAME from the item with the lowest price? I'm stuck on that and cannot continue.

    Thanks in advance.

  2. #2
    Valued Forum Contributor
    Join Date
    03-16-2012
    Location
    Aarhus, Denmark
    MS-Off Ver
    Excel 2007
    Posts
    992

    Re: Grocery List with Price comparison

    Try:

    =INDEX($B$2:$F$2,MATCH(G3,B3:F3,0)) in H3 and copy down.
    Sincerely
    S?ren Larsen

    "Give a man a fish, and you'll feed him for a day. Give a man a fishing rod, and he'll steal your yacht!"

  3. #3
    Registered User
    Join Date
    10-22-2007
    Location
    Mumbai, India
    MS-Off Ver
    MS Excel 2007
    Posts
    59

    Re: Grocery List with Price comparison

    one of the workaround, copy this formula on H3 and drag it down:

    Please Login or Register  to view this content.

  4. #4
    Registered User
    Join Date
    04-04-2012
    Location
    South Africa
    MS-Off Ver
    2010
    Posts
    4

    Re: Grocery List with Price comparison

    Grocery List.xlsx

    Thanks for the quick responses. I'm getting errors on both of these formulas and I don't fully understand how they work so it's hard to correct the errors.

    I'm attaching the file for you to look at.

    Thanks again

  5. #5
    Registered User
    Join Date
    10-22-2007
    Location
    Mumbai, India
    MS-Off Ver
    MS Excel 2007
    Posts
    59

    Re: Grocery List with Price comparison

    i pasted my formula in cell h3 in your file and it worked properly
    however, it will throw an error at cell h5 since there is no data available and to avoid this use an error trapping formula mentioned below:

    Please Login or Register  to view this content.

  6. #6
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Grocery List with Price comparison

    For Søren's formula, in H3

    =IFERROR(INDEX($B$2:$F$2,MATCH(G3,B3:F3,0)),"")

    Roshan's can also be simplified with the IFERROR (since you say you have Excel 2010)
    =IFERROR(OFFSET($B$2,0,MATCH(G3,B3:F3,0)-1)),"")
    Hope that helps.
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  7. #7
    Registered User
    Join Date
    04-04-2012
    Location
    South Africa
    MS-Off Ver
    2010
    Posts
    4

    Re: Grocery List with Price comparison

    Thanks Roshan10043

    I found where my problem was, my Excel 2010 does not like commas so I replaced all commas with semi-colons and it worked.

    Thanks for your help!

  8. #8
    Valued Forum Contributor
    Join Date
    03-16-2012
    Location
    Aarhus, Denmark
    MS-Off Ver
    Excel 2007
    Posts
    992

    Re: Grocery List with Price comparison

    Ahh yes, I was thinking about that. It's got nothing to do with your version of Excel, but with the languagepack. American uses "," whereas Danish and apparently also South African (British?) uses ";".

  9. #9
    Registered User
    Join Date
    04-04-2012
    Location
    South Africa
    MS-Off Ver
    2010
    Posts
    4

    Re: Grocery List with Price comparison

    Thanks to everyone for the quick responses!

    Appreciate all the help.

+ 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