+ Reply to Thread
Results 1 to 3 of 3

An "AND" inside an "OR inside an "IF"

  1. #1
    Registered User
    Join Date
    02-05-2008
    Location
    NJ, USA
    Posts
    2

    An "AND" inside an "OR inside an "IF"

    Hello everyone:

    Need some wisdom here. I am trying to nest 2 "AND" conditionals within an "OR" within an "IF". It works like this: first it has to check gender and a number, say female and >98 -or- male and >102. If the gender and the number are true, then "whatever name", if not true, "this other name". I am having trouble nesting the "and"s inside the "OR". Suggestions?

    Thank you very much for any help you can provide.
    Last edited by Charliebrown190; 02-05-2008 at 11:08 AM.

  2. #2
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    See if this works, assuming the gender is in A1 and number in A2:

    =IF(OR(AND(A1="female",A2>98), AND(A1="male",A2>102)),"whatever name","this other name")

    HTH

    Jason

  3. #3
    Registered User
    Join Date
    02-05-2008
    Location
    NJ, USA
    Posts
    2

    Thank you

    Thank you Jason:

    This worked like a charm. Take care.

+ 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