If I have an existing custom field where there are some duplicate values across records, but which should ideally be a unique key, is it possible to make it unique? If so, what happens to the existing records with duplicate values?
You won't be allowed to complete the modification. All values must already be unique or null before imposing a unique index. You'll get an error like the following:
Error: Duplicate value(s) found when building unique index, example: ...
You must first clean up the duplicate values before you'll be allowed to make an index.