I have tables with UNIQUEIDENTIFIERS as the primary keys. The default is NEWSEQUENTIALID(), to help with generating keys in ascending order by default. After inserting records into the tables, I want to be able to return the key value which was just inserted. This doesn't seem possible with the NEWSEQUENTIALID() default. I've seen examples where an insert stored procedure will generate a random key with SELECT @SomeVariable = NEWID()--then using that value to insert into the table and return to the calling connection. However, NEWID() is less than desirable in this case. Does anyone have any ideas how to get that value back with the current set up I've described?
Thanks
Thanks