SET 语句有多种形式。与特定服务器功能无关联的表单描述见本节各小节:The SET
statement has several forms. Descriptions for those forms that are
not associated with a specific server capability appear in
subsections of this section:
SETenables you to assign values to variables that affect the operation of the server or clients. See 第 15.7.6.1 节,“变量赋值的 SET 语法”.var_name=valueSETenables you to assign values to variables that affect the operation of the server or clients. See Section 15.7.6.1, “SET Syntax for Variable Assignment”.var_name=valueSET CHARACTER SETSET NAMES与当前服务器连接相关的字符集和排序变量分配值。参见 Section 15.7.6.2, “SET CHARACTER SET Statement”, and 第 15.7.6.3 节, “SET NAMES Statement”。SET CHARACTER SETandSET NAMESassign values to character set and collation variables associated with the current connection to the server. See Section 15.7.6.2, “SET CHARACTER SET Statement”, and Section 15.7.6.3, “SET NAMES Statement”.
其他表单的描述在其他地方,与它们帮助实现的功能相关的其他语句分组:Descriptions for the other forms appear elsewhere, grouped with other statements related to the capability they help implement:
SET DEFAULT ROLESET ROLE设置用户账户的默认角色和当前角色。参见 第 15.7.1.9 节,“SET DEFAULT ROLE Statement”,以及 第 15.7.1.11 节,“SET ROLE Statement”。SET DEFAULT ROLEandSET ROLEset the default role and current role for user accounts. See Section 15.7.1.9, “SET DEFAULT ROLE Statement”, and Section 15.7.1.11, “SET ROLE Statement”.SET PASSWORD分配账户密码。参见 第 15.7.1.10 节,“SET PASSWORD Statement”。SET PASSWORDassigns account passwords. See Section 15.7.1.10, “SET PASSWORD Statement”.SET RESOURCE GROUP将线程分配到资源组。参见 第 15.7.2.4 节,“SET RESOURCE GROUP Statement”。SET RESOURCE GROUPassigns threads to a resource group. See Section 15.7.2.4, “SET RESOURCE GROUP Statement”.SET TRANSACTION ISOLATION LEVEL事务处理的隔离层。参见 第 15.3.7 节,“SET TRANSACTION Statement”。SET TRANSACTION ISOLATION LEVELsets the isolation level for transaction processing. See Section 15.3.7, “SET TRANSACTION Statement”.