Error validating the default for column id newsequentialid
For example, you cannot execute the following: CREATE TABLE my Table (Column A uniqueidentifier DEFAULT dbo.myfunction(NEWSEQUENTIALID())) ... Creates a GUID that is greater than any GUID previously generated by this function on a specified computer since Windows was started.But the important part is that the Guid are "ordered" in a way that do not cause page splits (if the Guid is used in a index) and this is what happens when using the new sequential guid.
I put that value in the default properties, but it returns a validation error when clicking away from the default value field in the table design.
Any help would be great, otherwise I'll have to write a trigger.
Or you can use an ALTER TABLE statement to bypass the error and still set the default to newsequentialid(). I guess you're referring to int ID's (also known as identity column) which can have a seed and increment values, which I already have in my current table.
FYI, this is a sample 'uniqueidentifier' value: 41cbbcd0-95fe-4c8f-9985-8b4ee8c5e49c Mike, There you have the answer to my question!
The first command works fine but the second turns out showing an error message 'error validating the default for column xxxx' That's apparently a bug in sql enterprise manager.