Check a box in new column if duplicate value is found within a particular column
Hello,
I'm trying to move a row to a new sheet when a duplicate serial number is added to a sheet through a form entry. Is there a formula I can use to check a box if a duplicate value is found in a serial number column of a sheet?
Thanks,
Mary
Best Answers
-
Your are looking for a if(max(collect to determine the newest entry, something like this
=(IF([Created Date]@row = MAX(COLLECT([Created Date]:[Created Date], [Serial Number]:[Serial Number], [Serial Number]@row)), 1, 0))
-
Hey @Mary Corvalan
Paul's formula above works terrific for newest entry. For specifically finding duplicates, you can use this approach to mark duplicate rows as they occur. You will need either the Created date or If you are adding rows chronologically system autonumber column [Row ID]. I will use the [Row ID] in my example but Created can be used instead.
This formula checks the original row when a duplicate is added.
=IF(COUNTIFS([serial number]:[serial number], [serial number]@row, [Row ID]:[Row ID], @cell <= [Row ID]@row) > 1, 1)
If you need the duplicate row marked instead, then use the formula below
=IF(COUNTIFS([serial number]:[serial number], [serial number]@row, [Row ID]:[Row ID], @cell > [Row ID]@row) =2, 1)
Will either of these work for you?
Kelly
Answers
-
Your are looking for a if(max(collect to determine the newest entry, something like this
=(IF([Created Date]@row = MAX(COLLECT([Created Date]:[Created Date], [Serial Number]:[Serial Number], [Serial Number]@row)), 1, 0))
-
Hey @Mary Corvalan
Paul's formula above works terrific for newest entry. For specifically finding duplicates, you can use this approach to mark duplicate rows as they occur. You will need either the Created date or If you are adding rows chronologically system autonumber column [Row ID]. I will use the [Row ID] in my example but Created can be used instead.
This formula checks the original row when a duplicate is added.
=IF(COUNTIFS([serial number]:[serial number], [serial number]@row, [Row ID]:[Row ID], @cell <= [Row ID]@row) > 1, 1)
If you need the duplicate row marked instead, then use the formula below
=IF(COUNTIFS([serial number]:[serial number], [serial number]@row, [Row ID]:[Row ID], @cell > [Row ID]@row) =2, 1)
Will either of these work for you?
Kelly
-
Thank you both so much!! I've been using the formulas and setting up my workflow. I ended up using The formula checks the original row when a duplicate is added but I changed the "<"to ">". For some reason that worked better. This selected the original entry and I set up a move automation to have it sent to an archive sheet. 😀
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.5K Get Help
- 424 Global Discussions
- 136 Industry Talk
- 465 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 145 Just for fun
- 63 Community Job Board
- 465 Show & Tell
- 32 Member Spotlight
- 1 SmartStories
- 301 Events
- 39 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!