Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Creating Sequences in Sql Server

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-10-14 : 13:01:50
Brian writes "I am creating a database for a Three Tier Web based system. I am planning on using surrogate keys on every table so that I don't need to do any cascade updates. In Oracle I can easily create functions that provide the neccesary values for each table using sequences. I can even combine the logic into one function that will return a pkey for any table, given that the function accepts the table name as a parameter.

How can I do this in SQL Server. I thought about creating a single table to store all of the values and just updating that table, but that would require row level locking. Any information, white papers, etc would be appreciated. I haven't seen any information on how to create something like this.

Thank you in advance,

Brian."
   

- Advertisement -