How to detect duplicate artifacts in DNG
Does anyone know of a method or utility that enables a user to identify duplicate artifacts (artifacts with identical content) within a DNG project area?
- Built-in DNG functionality of which I am not aware
- A creative SPARQL query in JRS
- A JavaScript OpenSocial gadget
- Other?
Accepted answer
I have a couple of thoughts ...
Let's assume "identical" means "same title and content and attributes but different ID number." I suggest this because ...
1. If you import multiple times, for example from a CSV or Excel file, you could experience this if you don't select update or replace.
2. If you have identical ID numbers in the same project area (or, I think, on the same server) then it's a bug (I don't think that's possible except in the special case of a configuration-enabled project where you have reorganized artifacts into different components and have old and new versions of the same artifact in different components).
If your artifact titles tend to be relatively long and unique (or the content tends to be relatively short and unique), then a JRS report might be the best way to find them (create report, sort by title then description and scan for duplicates).
If not, then it may be most productive to create a DNG extension that reads requirements, creates a hash of the relevant fields, then stores the hash and artifact ID somewhere (and maybe stores more info for convenience). Then you could find identical hashes.