>Hi to all,
>
>I am to pass my application in VFP for Client/server (SQL-Server), as to know which number it of the last customer to increment this number before the TABLEUPDATE and to effect this operation without that another user can have access to this number. I cannot use the Identity property of the SQL-server because the field is not unique. Which the best form to effect this operation?
>
>
>Thanks
>Carla Silva
Carla,
This is from 'Inside MS SQL server inside 7.0' as is (p:39).
"SQL server makes it easy to efficiently generate unique numbers by allowing one column in a table to have the
Identity property. You use the Identity property to make sure that each value in the column is unique and that the values will increment ( or decrement ) by amount you specify from a starting point that you specify. ( A column having the Identity property will typically also have a PRIMARY KEY or UNIQUE constraint, but this isn't required.)"
And this is from online help as is :
"Although the IDENTITY property automates row numbering within one table, separate tables, each with its own identifier column, can generate the same values. This is because the IDENTITY property is guaranteed to be unique only for the table on which it is used. If an application must generate an identifier column that is unique across the entire database, or every database on every networked computer in the world, use the ROWGUIDCOL property, the uniqueidentifier data type, and the NEWID function."
Cetin