+ Reply to Thread
Results 1 to 5 of 5

merge 2 formulas

  1. #1
    Forum Contributor max_max's Avatar
    Join Date
    06-28-2013
    Location
    italy - venice
    MS-Off Ver
    Excel 2007
    Posts
    1,693

    merge 2 formulas

    Hello
    I have these 2 formulas:

    =IF ( D7 > D8 , C7 , C8 )
    =IF ( D7 < D8 , C8 , C7 )


    unendole dovrebbere essere:

    = IF (( D7 > D8 , C7 , C8 ) ; IF ( D7 < D8 , C8 , C7 ) , "" )

    but makes a mistake, where am I wrong?
    max_max

  2. #2
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: merge 2 formulas

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    My General Rules if you want my help. Not aimed at any person in particular:

    1. Please Make Requests not demands, none of us get paid here.

    2. Check back on your post regularly. I will not return to a post after 4 days.
    If it is not important to you then it definitely is not important to me.

  3. #3
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: merge 2 formulas

    hi max_max. and the reason why your formula is not working is because:
    1. i don't know if it's for clearer presentation, but you need to get rid of the spaces after the formula name:
    = IF_(

    2. you need to follow the Excel tip when doing the formula. when you type in the first IF(, you will see Excel show:
    logical_test,[value_if_true],[value_if_false]
    the bold part is where you are working on.

    your 2nd open parenthesis after the IF formula is unnecessary. = IF ((
    so your logical_test should be:
    D7 > D8

    now confirm your logical_test by pressing comma. that will result in the excel tip to be:
    logical_test,[value_if_true],[value_if_false]

    so if D7 is greater than D8, you want to show C7.
    put a comma to confirm and the excel tip now shows:
    logical_test,[value_if_true],[value_if_false]

    because you want to add in more tests, you cannot end this argument with C8. if it's FALSE (ie D7 NOT greater than D8), you want to input another logical test. so:
    = IF( D7 > D8 , C7 , IF( D7 < D8

    again, if the logical test is TRUE, show C8, and if it's FALSE, it means it has failed both the 1st logical test (D7 NOT greater than D8) and 2nd logical test (D7 NOT lesser than D8). that leaves only 1 possibility; equals to D8. so just leave the last [value_if_false] as blank. close two parenthesis as you used two IFs.
    = IF( D7 > D8, C7, IF( D7 < D8, C8, "" ))

    another way though:
    =CHOOSE(SIGN(D7-D8)+2,C8,"",C7)

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  4. #4
    Forum Contributor max_max's Avatar
    Join Date
    06-28-2013
    Location
    italy - venice
    MS-Off Ver
    Excel 2007
    Posts
    1,693

    Re: merge 2 formulas

    Hello,
    thank you all.
    max_max

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2407 (Windows 11 23H2 64-bit)
    Posts
    82,858

    Re: merge 2 formulas

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Modify 2 formulas, Merge two formulas into one formula
    By score in forum Excel General
    Replies: 7
    Last Post: 01-09-2015, 12:24 PM
  2. [SOLVED] How do I merge these two formulas?
    By nwb in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-24-2014, 01:23 PM
  3. Merge 2 formulas into one
    By hitman989 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-10-2014, 05:06 PM
  4. [SOLVED] Merge the two formulas together?
    By Dougiebn in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-26-2013, 03:52 PM
  5. How to merge two different formulas
    By hirenhkansara in forum Excel General
    Replies: 2
    Last Post: 08-24-2012, 08:13 AM
  6. How to merge two different formulas
    By hirenhkansara in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-24-2012, 07:50 AM
  7. Excel 2007 : Merge two formulas together
    By colins in forum Excel General
    Replies: 3
    Last Post: 02-20-2010, 10:57 AM

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