+ Reply to Thread
Results 1 to 6 of 6

formula for multiple criteria with an exception

  1. #1
    Registered User
    Join Date
    03-18-2014
    Location
    burlington, nj
    MS-Off Ver
    Excel 365
    Posts
    73

    Question formula for multiple criteria with an exception

    Is there an "If UNLESS" formula in excel or workaround for it?

    I have attached the file to make it easier to explain.

    I have column A which has two options for the name "Sales" & "Sales-Marketing"
    I have column B which has sub dept. name - It is either no value in a cell or General
    Now I have an excel formula in column C which I want to pull as below:

    If column A shows "Sales" & column B with "No value in cell" then the answer is "Sales"
    If Column A shows "Sales-Marketing" & Column B with "No value in cell" then the answer is "Marketing".
    If column A shows "Sales" & Column B shows "General" then I want the excel formula to pull "Marketing"

    So I am having difficulty when there is a value in column B.
    Attached Files Attached Files
    Last edited by vani2004; 10-20-2022 at 11:58 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,218

    Re: If UNLESS formula

    Administrative Note:

    We would very much like to help you with your query, however the thread title does not really convey what your request is about. Tell us what you are trying to do, not how you think it should be done.

    Please take a moment to amend your thread title. Make sure that the title properly explains your request. Your title should be explicit and not be generic (this includes function names used without an indication of what you are trying to achieve).

    Please see Forum Rule #1 about proper thread titles and adjust accordingly. To edit the thread title, open the original post to edit and then click on Go Advanced (bottom right) to access the area where you can edit your title.

    (Note: this change is not optional. No help to be offered until this moderation request has been fulfilled.)
    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. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: If UNLESS formula

    Try:
    =IF(A2="","",IF(AND(A2="Sales",B2=""),A2,"Marketing"))
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  4. #4
    Registered User
    Join Date
    03-18-2014
    Location
    burlington, nj
    MS-Off Ver
    Excel 365
    Posts
    73

    Re: If UNLESS formula

    Sorry! I amended it and hope it meets the guideline. If not i can re-amend it. Big thanks to everything you all do to help us.

  5. #5
    Registered User
    Join Date
    03-18-2014
    Location
    burlington, nj
    MS-Off Ver
    Excel 365
    Posts
    73

    Re: If UNLESS formula

    Quote Originally Posted by Glenn Kennedy View Post
    Try:
    =IF(A2="","",IF(AND(A2="Sales",B2=""),A2,"Marketing"))
    It worked! Thank you for the quick reply too

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: formula for multiple criteria with an exception

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

    Finally, if that takes care of your original question, please click on "Thread Tools" from the menu link (just above the first post in the thread) and mark this thread as SOLVED.

+ 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. Replies: 3
    Last Post: 03-24-2020, 07:27 AM
  2. Replies: 3
    Last Post: 01-10-2019, 09:34 AM
  3. Replies: 5
    Last Post: 02-16-2018, 06:50 AM
  4. Replies: 8
    Last Post: 09-22-2017, 05:41 AM
  5. Excel formula bar to display the result of the formula , not the formula?
    By max_max in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-18-2016, 07:15 PM
  6. Replies: 11
    Last Post: 06-06-2014, 03:34 PM
  7. how to hide formula in formula box, view lookup result in formula box?
    By vengatvj in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-14-2013, 04:06 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