But of course.


    SELECT NewId()



You may also use NewId function as a default value of uniqueidentifier field type in a table definition. Just add it to your create table statement like this:


    [MyField] [uniqueidentifier] NOT NULL DEFAULT (NewId())

0 comment(s) :

Newer Post Older Post Home

Blogger Syntax Highliter