SQL Server 全局唯一标识符 [英] SQL Server Globally Unique Identifiers

查看:53
本文介绍了SQL Server 全局唯一标识符的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

何时或为什么需要使用全局唯一标识符而不是传统的 Idenity 列?请帮我理解

When or why will one need to use Globally Unique Identifiers instead of the traditional Idenity column? Please help me understand

推荐答案

一个原因是复制和可扩展性:当存在多个不协调的编写者时,他们——根据定义——没有沟通的渠道用于为主键创建唯一的 int .GUID 不需要通信即可保持唯一性.

One reason is replication and scalability: When multiple, uncoordinated writers exist, they -- by definition -- have no channel to communicate for creating unique ints for the primary key. GUIDs don't need communication to be unique.

这篇关于SQL Server 全局唯一标识符的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆