+ Reply to Thread
Results 1 to 9 of 9

Highlighting duplicate pairs across columns

  1. #1
    Registered User
    Join Date
    03-29-2016
    Location
    Winchester, England
    MS-Off Ver
    Mac 2011
    Posts
    8

    Highlighting duplicate pairs across columns

    Hi All

    I have two columns of data and would like to highlight those values that are duplicated across both columns as in the example below.

    Untitled.png

    If it is easier to highlight unique pairs (the white ones) instead that would be ok too.

    many thanks
    Last edited by Zorbadog; 11-08-2019 at 11:07 AM.

  2. #2
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: Highlighting duplicate pairs across columns

    Apply this CF rule: =OR(AND($A3=$A2,$B3=$B2),AND($A3=$A4,$B3=$B4))
    Click the * to say thanks.

  3. #3
    Registered User
    Join Date
    03-29-2016
    Location
    Winchester, England
    MS-Off Ver
    Mac 2011
    Posts
    8

    Re: Highlighting duplicate pairs across columns

    Hi PaulM100

    Many thanks. I have tried this but it only seems to highlight the bottom two rows.
    Last edited by Zorbadog; 11-08-2019 at 01:22 PM.

  4. #4
    Registered User
    Join Date
    03-29-2016
    Location
    Winchester, England
    MS-Off Ver
    Mac 2011
    Posts
    8

    Re: Highlighting duplicate pairs across columns

    The 'remove duplicates' function is exactly what i need, I just need them highlighted instead of removed! Or a number ie 1 added to another column so I can filter.

  5. #5
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: Highlighting duplicate pairs across columns

    Conditional formatting is used.
    Select A3:B8
    Home --> Conditional formatting --> NNew Rule
    Use a formula to determine which cells to format
    Paste the below formula
    Format for the color
    OK-->OK

    =COUNTIFS($A$3:$A$8,$A3,$B$3:$B$8,$B3)>1
    Attached Files Attached Files
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  6. #6
    Registered User
    Join Date
    03-29-2016
    Location
    Winchester, England
    MS-Off Ver
    Mac 2011
    Posts
    8

    Re: Highlighting duplicate pairs across columns

    Quote Originally Posted by kvsrinivasamurthy View Post
    Conditional formatting is used.
    Select A3:B8
    Home --> Conditional formatting --> NNew Rule
    Use a formula to determine which cells to format
    Paste the below formula
    Format for the color
    OK-->OK

    =COUNTIFS($A$3:$A$8,$A3,$B$3:$B$8,$B3)>1

    Thank you very much but not sure it is still quite right. If I try it on the attached it does not give the correct results. The 24 XXX's and the 14 yyy's should highlight.

    Book1.xlsx

    regards

  7. #7
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: Highlighting duplicate pairs across columns

    =COUNTIFS($A$1:$A$10,$A3,$B$1:$B$10,$B1)>1

    Formula applied is not correct for A1:B10

    Corrected formula is here

    =COUNTIFS($A$1:$A$10,$A1,$B$1:$B$10,$B1)>1
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    03-29-2016
    Location
    Winchester, England
    MS-Off Ver
    Mac 2011
    Posts
    8

    Re: Highlighting duplicate pairs across columns

    Quote Originally Posted by kvsrinivasamurthy View Post
    =COUNTIFS($A$1:$A$10,$A3,$B$1:$B$10,$B1)>1

    Formula applied is not correct for A1:B10

    Corrected formula is here

    =COUNTIFS($A$1:$A$10,$A1,$B$1:$B$10,$B1)>1
    That work perfectly. Thank you very much.

  9. #9
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: Highlighting duplicate pairs across columns

    Welcome. Thanks foe feedback and rep.

+ 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. [SOLVED] Highlight duplicate dates who share unique ID
    By Andrewjs in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-17-2017, 03:41 PM
  2. [SOLVED] Highlight Rows of Duplicate results column with unique coloring
    By G-Co in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 07-24-2017, 07:09 PM
  3. Replies: 3
    Last Post: 06-20-2017, 04:21 AM
  4. [SOLVED] Highlight a unique value with duplicate entries
    By scotland9 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-03-2015, 09:47 AM
  5. [SOLVED] Highlight cells that are duplicate pairs
    By erob223 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-22-2015, 10:46 AM
  6. Replies: 10
    Last Post: 01-05-2011, 03:26 AM
  7. Excel 2007 : Highlight matching pairs-Excel 2007
    By Rob44 in forum Excel General
    Replies: 11
    Last Post: 12-26-2010, 07:58 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