none
Help deleting duplicates based on the highest value on a second column RRS feed

  • Question

  • I have over 20k rows of data and I'm trying to delete all of the rows with old revisions. Basically keep the duplicate row that has the largest value on the second column.

    I would like to go from this:

    3455P001 0
    3455P002 1
    3455P002 0
    000N3772 0
    3772G001 0
    3773P001 0
    4215P001 0
    4219P001 0
    4221P001 0
    4223G001 4
    4223G001 3
    4223G001 2
    4223G001 1
    4223G001 0
    4223G002 4
    4223G002 3
    4223G002 2
    4223G002 1
    4223G002 0

    To this:

    3455P001       0
    3455P002       1
    000N3772       0
    3772G001       0
    3773P001       0
    4215P001       0
    4219P001      0
    4221P001      0
    4223G001      4
    4223G002      4


    Sorry if my explanation is not adequate enough. I'm new to VBA and the basic RemoveDuplicates() command hasn't worked out for me. I would appreciate any help, thanks!

    Wednesday, September 25, 2019 1:54 PM

Answers