Mysql:Changes in MySQL 5.7.13 (2016-06-02, General Availability):maximum length of MySQL user names was increased from 16 to 32 characters
Changes in MySQL 5.7.13 (2016-06-02, General Availability)
-
In MySQL 5.7.8, the maximum length of MySQL user names was increased from 16 to 32 characters, but some applicable contexts for this increase were overlooked. Additional changes in maximum user name length now have been applied:
-
The size of these
mysql
system table columns is increased:-
The
definer
column of theevent
andproc
tables -
The
grantor
column of theprocs_priv
andtables_priv
tables
In each case, the column previously was defined as
CHAR(77)
, where 77 was chosen to permit a
string containing a user name up to 16 characters, auser_name
@host_name
@
character, and a host name up to 60 characters. Each column now is defined asCHAR(93)
, reflecting an increase in permitted user name length from 16 to 32 characters. -
-
A similar change from
CHAR(77)
toCHAR(93)
applies to theDEFINER
column of theseINFORMATION_SCHEMA
tables:EVENTS
,ROUTINES
,TRIGGERS
,VIEWS
. Along with the changes toINFORMATION_SCHEMA
tables, output from any correspondingSHOW
statements now displaysDEFINER
values up to 93 characters. Examples of affected statements:SHOW EVENTS
,SHOW TRIGGERS
,SHOW PROCEDURE STATUS
.
If you upgrade to this MySQL release from an earlier version, you must run mysql_upgrade (and restart the server) to incorporate the changes to the
mysql
system database. A server from MySQL 5.7.13 or higher for which mysql_upgrade has not been run continues to permit a maximum of 77 characters in the system tables mentioned previously, and anER_USER_COLUMN_OLD_LENGTH
error will occur in those system table contexts where a
value from 78 to 93 characters long is given.user_name
@host_name
-
-
It is possible to use
ALTER TABLE
to change the default value of a columncol_name
, which may change the value of a generated column expression that refers to the column usingDEFAULT(
. For this reason,col_name
)ALTER TABLE
operations that change the definition of a column now cause a table rebuild if any generated column expression usesDEFAULT()
. (Bug #80299, Bug #22680839)
It is possible to use ALTER TABLE
to change the default
value of a column col_name
, which may
change the value of a generated column expression that refers to the column
using DEFAULT(
. For this reason, col_name
)ALTER TABLE
operations that change
the definition of a column now cause a table rebuild if any generated column
expression uses DEFAULT()
.
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· C#/.NET/.NET Core优秀项目和框架2025年2月简报
· Manus爆火,是硬核还是营销?
· 终于写完轮子一部分:tcp代理 了,记录一下
· 【杭电多校比赛记录】2025“钉耙编程”中国大学生算法设计春季联赛(1)