+ Reply to Thread
Results 1 to 5 of 5

Help with multiple IF and OR statements

Hybrid View

  1. #1
    Registered User
    Join Date
    11-20-2010
    Location
    Warwick, RI
    MS-Off Ver
    Excel 2007
    Posts
    13

    Help with multiple IF and OR statements

    I'm trying to put together a formula for all of my ebay final value fees (which are entirely too complicated,) I think I have the basics down but the math does not come out right. Somebody please help.

    =IF(J13="YES",(IF(G13="Electronics",IF(L13<=50,L13*0.08,(OR(L13>=50.01,L13<=1000)*L13-50*0.05+(0.08*50))),IF(G13="Clothing",IF(L13<=50,L13*0.12,(OR(L13>=50.01,L13<=1000)*L13-50*0.09+(0.12*50))),IF(G13="Books",IF(L13<=50,L13*0.15,(OR(L13>=50.01,L13<=1000)*L13-50*0.05+(0.15*50))),IF(G13="Other",IF(L13<=50,L13*0.12,(OR(L13>=50.01,L13<=1000)*L13-50*0.06+(0.12*50)))))))),"NO")

    G13 = is the category for which the item belongs and then has a corresponding formula depending on the price sold

    J13 = asks me if the item was buy it now or not if yes then it just has to use the formulas that are listed

    L13 = price sold
    Last edited by Rooster35236; 11-22-2010 at 05:36 PM.

  2. #2
    Valued Forum Contributor Blake 7's Avatar
    Join Date
    10-01-2010
    Location
    Bogota, Colombia
    MS-Off Ver
    Excel 2010 64 bit and Excel 2007,
    Posts
    1,377

    Re: Help with multiple IF and OR statements

    Roost - can you post a sample of your workbook? it would make it easier for people to follow. Also, describe your desired outcome. It maybe that your if formula is inefficient and not the right function.
    Blake 7

    If your question has been answered, please click EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.

    If any member's response has helped to solve your problem, please consider using the scales icon on the top right of their post to show your appreciation.

    http://failblog.org/

  3. #3
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help with multiple IF and OR statements

    You would have to check the math, but perhaps?

    =IF(J13="YES",IF(L13<50,L13*LOOKUP(L13,{"Books","Clothing","Electronics","Other"},{0.15,0.12,0.08,0.12}),IF(L13<=1000,L13-50*LOOKUP(L13,{"Books","Clothing","Electronics","Other"},{0.05,0.09,0.05,0.06})+50*LOOKUP(L13,{"Books","Clothing","Electronics","Other"},{0.15,0.12,0.08,0.12}),"What_if_over_1000")),"No")
    replace this: "What_if_over_1000" with what you want to happen if L13 is over 1000....

    Be careful of order operations in these statements: L13-50*0.05+(0.08*50)

    the multiplications happen first, then the result of 50*0.05 is subtracted from L13 and the result of all that is added to 0.08*50
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  4. #4
    Registered User
    Join Date
    11-20-2010
    Location
    Warwick, RI
    MS-Off Ver
    Excel 2007
    Posts
    13

    Talking Re: Help with multiple IF and OR statements

    Wow that's good I've been scratching my head over this one for the past 2 days thanks so much!

  5. #5
    Registered User
    Join Date
    10-05-2010
    Location
    S.A
    MS-Off Ver
    Excel 2007
    Posts
    99

    Re: Help with multiple IF and OR statements

    you may use this formula also:
    =IF(J13="yes",IF(AND(G13="electronics",L13<=50),L13*0.08,IF(AND(G13="electronics",L13>=50.01,L13<=1000),L13-50*0.05+(0.08*50),IF(AND(G13="clothing",L13<=50),L13*0.12,IF(AND(G13="clothing",L13>=50.01,L13<=1000),L13-50*0.09+(0.12*50),IF(AND(G13="books",L13<=50),L13*0.15,IF(AND(G13="books",L13>=50.01,L13<=1000),L13-50*0.05+(0.15*50),IF(AND(G13="other",L13<=50),L13*0.12,IF(AND(G13="other",L13>=50.01,L13<=1000),L13-50*0.06+(0.12*50))))))))),"no")

+ 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