Put the different numbers in the two rows on the third row

BABY_JOJO 241 Reputation points
2023-03-14T15:20:38.8133333+00:00

Put the different numbers in the two rows on the third row.

1 Row: 1 2 4 5 7

2 Row: 1 4 6 7 8

Result 3 Row: 2 5 6 8

Microsoft 365 and Office | Excel | For business | Windows
0 comments No comments
{count} votes

Answer accepted by question author
  1. Emi Zhang-MSFT 30,126 Reputation points Microsoft External Staff
    2023-03-15T02:24:10.5133333+00:00

    Hi @BABY_JOJO,

    Try this formula:

    =IFERROR(SMALL(IF(COUNTIF(1:2,$A1:$Z2)=1,$A1:$Z2),COLUMN()),"")

    User's image

    Just checking in to see if the information was helpful. Please let us know if you would like further assistance.


    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Ashish Mathur 101K Reputation points Volunteer Moderator
    2025-07-27T23:57:38.8666667+00:00

    Hi,

    In cell A5, enter this formula

    =UNIQUE(TOROW(A2:E3),TRUE,TRUE)

    Hope this helps.

    User's image

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.