Implications of using Unique Negative Numbers??

  • Guys,

    We have a table across 12 databases. we were using positive int as a unique identifier but now we are out of range so we are thinking of using negative numbers from -2 billion to 0 for the same.....

    any problem which we may come across in the future??

  • Not that I'm aware of. Brian has done some of this using Distributed Partiitoned views. As long as your app is ok with it, should be ok.

    Steve Jones

    sjones@sqlservercentral.com

    http://www.sqlservercentral.com/columnists/sjones

    http://www.dkranch.net

  • I have thought about this and the only thing I see is that you get about twice as many values, however unless you move the current values down it you reach 0 and role to one you have errors. Also, if clustered on this column and you leave the current values as is you will always be submitting early to the DB pages and pushing all your current data and may hurt performance. I would say also if you have a SQL 2000 server change to bigint and continue. That is all I can think of offhand.

  • Thx for your input guys!!

    Antares - Well, its going to take around 2 years to reach 0 and as far as DB performance we will have to think a solution for that, probably no clustered index.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply