Mongodb: Why can’t you set a unique value like this?

  mongodb, question



The new version does not allow unique index to be created in duplicate.

Because he also does not know how to deal with duplicate data

So remove the duplication and build it again.

Please refer to the following discussion posts: …