Skip to content
Advertisement

Set some default guid value in uniqueidentifier in sql

I need to set default guid value, not NEWID() in uniqueidentifier column in SQL.

For example: Have a column TestID in TestTable, need to set default TestID to "DA74F684-B228-48D5-9692-69465BE6D720".

Thank you in advance.

Advertisement

Answer

Here’s your script.

then, update exsting records

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement