Hi,
Thank you for coming Microsoft Q&A forum.
Duplicate Records are created due to the discovery data manager mechanism which runs a query and sorts the results by date. It will update the most recent returned result rather than the active result if more than 1 result is returned. Any subsequent AD discovery will then update the NULL or inactive entry in the database instead of the active entry.
You may try to create a collection for collecting the duplicate system with NULL record use the below query:
Select R.ResourceID,R.ResourceType,R.Name,R.SMSUniqueIdentifier,R.ResourceDomainORWorkgroup,R.Client from SMS_R_System as r full join SMS_R_System as s1 on s1.ResourceId = r.ResourceId full join SMS_R_System as s2 on s2.Name = s1.Name where s1.Name = s2.Name and s1.ResourceId != s2.ResourceId and R.Client = null
Once the collection is created and records are populated. Right click the collection and click show members, then select all items and click delete.
You may refer to the blog to get a deeper understanding of duplicate computer records:
(Third party link, just for your reference)
http://eskonr.com/2019/05/sccm-configmgr-collection-sql-identify-duplicate-computer-records-with-different-guid/
If the response is helpful, please click "Accept Answer" and upvote it.
Regards,
Allen