+ Reply to Thread
Results 1 to 7 of 7

IF Formula combination

  1. #1
    Forum Contributor
    Join Date
    02-09-2015
    Location
    malta
    MS-Off Ver
    Microsoft 365
    Posts
    383

    IF Formula combination

    Hi all,

    Hope all is well. I would like to ask for some ideas as to the following problem.


    Basically I have a spreadsheet with data written in two columns. Say as follows:



    Column A Column B

    1000 1010
    1010 1020
    1020 1030
    1040 1040
    1060 1050
    1080 1070

    Is there maybe a suggestion as to how I can create a formula or a set of formulas (maybe IF formulas or a combination) in Column C which which would include:
    if the number is found in Column A but not in B, include in C
    If the number is found in column B but not in A, include in C
    If the number is found in both column A and B, include the number from any column

    Therefore column C would look like:

    Column A Column B Column C

    1000 1010 1000
    1010 1020 1010
    1020 1030 1020
    1040 1040 1030
    1060 1050 1040
    1080 1070 1050
    ----- ----- 1060
    ----- ----- 1070
    ----- ----- 1080

    I don't know if this is possible using formulas. Thanks a lot for your ind help, appreciate a lot!

    Keibri
    Last edited by Keibri; 11-30-2015 at 03:54 PM.

  2. #2
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: IF Formula combination

    You get better help on your question if you add a small excel file, without confidential information.

    Please also add manualy the expected result in your file.

    To Attach a File:

    1. Scroll down to the window below your post Additional Options
    2. In the frame Attach Files you will see the button Manage Attachments
    3. Click the button.
    4. A new window will open titled Manage Attachments - Excel Forum.
    5. Click the Browse... button to locate your file for uploading.
    6. This will open a new window File Upload.
    7. Once you have located the file to upload click the Open button. This window will close.
    8. You are now back in the Manage Attachments - Excel Forum window.
    9. Click the Upload button and wait until the file has uploaded.
    10. Close the window and then click Submit.
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  3. #3
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,968

    Re: IF Formula combination

    I have a feeling I am missing something here, but lets try this as a start...
    A
    B
    C
    2
    1000
    1010
    1000
    3
    1010
    1020
    1020
    4
    1020
    1030
    1030
    5
    1040
    1040
    1040
    6
    1060
    1050
    1060
    7
    1080
    1070
    1080

    C2=IF(ISERROR(MATCH(A2,$B$2:$B$7,0)),A2,IF(ISNUMBER(MATCH(B2,$A$2:$A$7,0)),B2,IF(COUNTIF($C1:C$2,A2)>=1,B2,A2)))
    copied down
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  4. #4
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2405
    Posts
    13,427

    Re: IF Formula combination

    With your data in A2:B7 try array-entering this in C2 and filling down.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    If you aren’t familiar with array-entered formulas array enter means the formula must be committed from edit mode by simultaneously pressing and holding down Ctrl and Shift while hitting Enter.

    Results are this.

    Row\Col
    A
    B
    C
    2
    1000
    1010
    1000
    3
    1010
    1020
    1010
    4
    1020
    1030
    1020
    5
    1040
    1040
    1030
    6
    1060
    1050
    1040
    7
    1080
    1070
    1050
    8
    1060
    9
    1070
    10
    1080


    Edit A shorter version ... still array-entered ... would be
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by FlameRetired; 11-30-2015 at 07:31 PM.
    Dave

  5. #5
    Forum Contributor
    Join Date
    02-09-2015
    Location
    malta
    MS-Off Ver
    Microsoft 365
    Posts
    383

    Re: IF Formula combination

    Cheers thanks a ot for the answer it worked great Flameretired! Appreciate a lot!

  6. #6
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2405
    Posts
    13,427

    Re: IF Formula combination

    You are welcome. Glad it does the job, and thank you for the feedback.

  7. #7
    Forum Contributor
    Join Date
    02-09-2015
    Location
    malta
    MS-Off Ver
    Microsoft 365
    Posts
    383

    Re: IF Formula combination

    Really awesome! |Works like magic! That was a simply genius!

+ 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: 2
    Last Post: 03-13-2015, 01:44 PM
  2. [SOLVED] Need help : If formula combination
    By Jhon Mustofa in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 01-03-2014, 04:32 AM
  3. [SOLVED] Need help : Formula sum if with combination
    By Jhon Mustofa in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-07-2013, 12:51 PM
  4. sum and if combination in a formula
    By spindoctor in forum Excel General
    Replies: 1
    Last Post: 07-21-2009, 12:05 PM
  5. Formula Combination
    By Randy in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-05-2006, 08:00 PM
  6. [SOLVED] Help with a combination of formula's
    By Smiles in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 01-03-2006, 11:45 PM
  7. Help with combination formula
    By jessicawalton in forum Excel General
    Replies: 2
    Last Post: 01-14-2005, 05: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