What happens when DB engine runs out of numbers to use for primary keys?

前端 未结 10 1630
感情败类
感情败类 2021-01-18 10:59

Since DBs do not reuse numbers of deleted records it is possible to run out of numbers, especially if you pick not really a big integer type for this column.
What would

10条回答
  •  伪装坚强ぢ
    2021-01-18 11:19

    Most database systems have a numeric datatype that can be wider than 32 bits. If you anticipate more than 2^32 records you should use an appropriate key width.

提交回复
热议问题