Hi experts;
I need an advice for a specific issue.
I have a table with 65000 records. There are duplicate records in this table. These duplicate records depends on various fields. For example;
If name, surname and email info of a customer is the same;
If name, surname and mobile info of a customer is the same;
If name, surname and one of the other phone numbers is the same etc..
I need to match the records with these rules. By the way, I shouldnt delete duplicates, mark them with a number or another way and keep in the table.
Can you please share any usefull info? Should I use just TSQL and some queries? Any other specific software? Anyone has experience?
Thanks.
0
Comments
Where is the problem?
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
What should I do?
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
I tried it in sql query builder. Here is the query;
USE ProjectDB
UPDATE dbo.[BASETable]
SET DuplicateRecNo = (
SELECT TOP 1 RecordNo
FROM dbo.[ReferenceTable]
WHERE [ReferenceTable].Name = [BASETable].Name AND
[ReferenceTable].LastName = [BASETable].LastName AND
[ReferenceTable].EMail = [BASETable].EMail)
Thanks Kine;
Question is your code in NAV. Of course, going through 60000 record and filtering for 3 sets of filters could take some time, it is on you to display some dialog with the progress and check if all is optimized (indexes).
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.