I've been searching for an easy solution to a pretty trivial problem. I have an huge set of records (~120,000) that I need to screen for duplicates, assign a sequential number to each set of duplicates, like Assign#
below:
Eventually, I am trying to achieve this:
I use P1
, P2
, and P3
fields as a set of sort parameters in query (ascending/descending) to determine the best/top Name
for each set of identical NCBI hits.
I tried a lot of things already and my main problem is that access freezes half way through and I don't really know if the script is functional.
FROM [sortquery]
WHERE ((([sortquery].Name) In
(
SELECT TOP 1 [sortquery].Name
FROM [sortquery] AS Dupe
WHERE Dupe.NCBI=[sortquery].NCBI
ORDER BY Dupe.NCBI
)))
ORDER BY [sortquery].NCBI;
I am open to any suggestion and corrections! Thanks for any help =)