+ Reply to Thread
Results 1 to 6 of 6

Having trouble with IF, AND, OR logic with several greater than statements.

  1. #1
    Registered User
    Join Date
    08-10-2013
    Location
    Mississippi
    MS-Off Ver
    Excel Mac 2008
    Posts
    4

    Having trouble with IF, AND, OR logic with several greater than statements.

    I want to write a formula that compares three numbers. My cells are M2, X2, and AI2. My output cell is AJ2. So, if M2 is greater than X2 and AI2, then the output cell should read "Visual"; if X2 is greater than M2 and AI2, the output cell should read "Auditory"; if AI2 is greater than M2 and X2, the output cell should read "Tactile/Kinesthetic." I cannot for the life of me get this to work with IF, OR, AND, or a combo of those. Basically, this is a learning style survey for students. I have 600 students to survey, and I need fast data interpretation.

    Any help would be greatly appreciated!

  2. #2
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Having trouble with IF, AND, OR logic with several greater than statements.

    Hi addymarie & Welcome to the Forum,

    What if two of the cells are equal to each other?

    =IF(AND(M2>X2,M2>AI2),"Visual",IF(AND(X2>M2,X2>AI2),"Auditory",IF(AND(AI2>M2,AI2>X2),"Tactile/Kinesthetic","")))
    HTH
    Regards, Jeff

  3. #3
    Registered User
    Join Date
    08-10-2013
    Location
    Mississippi
    MS-Off Ver
    Excel Mac 2008
    Posts
    4

    Re: Having trouble with IF, AND, OR logic with several greater than statements.

    Jeff,

    That could totally happen, but I was going to deal with those individually rather than try to make an even more complicated formula. However, if you know a way to display both titles, that would work.

  4. #4
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Having trouble with IF, AND, OR logic with several greater than statements.

    You are right, the formula would get very complicated, but maybe just add to the end of the formula from above.

    If there is a number which equals another...

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    08-10-2013
    Location
    Mississippi
    MS-Off Ver
    Excel Mac 2008
    Posts
    4

    Re: Having trouble with IF, AND, OR logic with several greater than statements.

    Wow, that totally worked. I wish I had joined this forum before I spend 2.5 hours trying to figure it out myself. Can't thank you enough!!!!!

  6. #6
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Having trouble with IF, AND, OR logic with several greater than statements.

    You're welcome…glad you have a workable solution and thanks for the feedback...

    I wish I had joined this forum before I spend 2.5 hours trying to figure it out myself.
    Those 2.5 hours are never a waste, and believe me, you have learned that much more just by applying the effort.

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

+ 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. greater than or less than logic
    By JaredLMT in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-03-2012, 12:07 AM
  2. Logic Formula trouble
    By lmb23 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-27-2009, 10:48 AM
  3. Nested If statements / logic statements
    By Brainless_09 in forum Excel General
    Replies: 3
    Last Post: 06-17-2009, 02:59 PM
  4. Less than/ Greater than logic flipped.
    By nastech in forum Excel General
    Replies: 4
    Last Post: 03-27-2006, 05:55 PM
  5. [SOLVED] Less than/ Greater than logic flipped
    By nastech in forum Excel General
    Replies: 9
    Last Post: 03-27-2006, 05:50 PM

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