Sunday, February 19, 2012

Identity / Auto Incrementing Column

Hi,

I have an auto incrementing int column setup which serves as my unique primary key. Just wondering what happens when the auto increment reaches the limit? Will it recycle numbers from the begining (who's rows have obviously been deleted by this stage)?

trenyboy wrote:

Hi,

I have an auto incrementing int column setup which serves as my unique primary key. Just wondering what happens when the auto increment reaches the limit? Will it recycle numbers from the begining (who's rows have obviously been deleted by this stage)?

since int's maximum size is 2G once it's limit is exceeded you will have an arithmetic overflow. same goes with bigint.. although by then 2GB of rows this is a prime candidate for partioning already...Smile [:)]

No comments:

Post a Comment