How unique is UUID?

后端 未结 11 2037
终归单人心
终归单人心 2020-11-22 05:40

How safe is it to use UUID to uniquely identify something (I\'m using it for files uploaded to the server)? As I understand it, it is based off random numbers. However, it s

11条回答
  •  天命终不由人
    2020-11-22 05:56

    Been doing it for years. Never run into a problem.

    I usually set up my DB's to have one table that contains all the keys and the modified dates and such. Haven't run into a problem of duplicate keys ever.

    The only drawback that it has is when you are writing some queries to find some information quickly you are doing a lot of copying and pasting of the keys. You don't have the short easy to remember ids anymore.

提交回复
热议问题