This would only work on criminals too stupid to file off the id numbers. Better yet they could mismatch casings with the bullets and frame other people.
Well, a criminal could scatter some spent shells collected at a gun range. It would then be incumbant upon the innocent sportsperson to prove their innocence.