开发者

How are uniqueidentifiers calculated?

开发者 https://www.devze.com 2023-01-07 09:56 出处:网络
I was curious as to how SQL Server calculates uniqueidentifiers. I understand that uniqueidentifiers, are GUIDs but are these calculated based on system time?Or are they calculated based on the name o

I was curious as to how SQL Server calculates uniqueidentifiers. I understand that uniqueidentifiers, are GUIDs but are these calculated based on system time? Or are they calculated based on the name of job/script that has called the NEWID() function. I found this b开发者_如何学Pythonut i found this reference to be unclear.


I find the Wikipedia entry quite informative.


It depends on whether you are generating them from NEWID() or NEWSEQUENTIALID() (the last one uses an algorithm involving the mac address the first one doesn't)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号