j9九游会登录/ 云数据库 rds_云数据库 rds for mysql/ / / 自增属性auto_increment为什么未在表结构中显示
更新时间:2025-04-09 gmt 08:00

自增属性auto-j9九游会登录

场景描述

创建表时,添加了自增属性auto_increment,执行show create table,自增属性未在表结构中显示。

创建表:

执行show create table xxx,未显示自增属性auto_increment:

原因分析

经过排查,是因为参数“sql_mode”设置了no_field_options属性。

sql_mode相关属性介绍:

  • no_field_options:不要在show create table的输出中打印mysql专用列选项。
  • no_key_options:不要在show create table的输出中打印mysql专用索引选项。
  • no_table_options:不要在show create table的输出中打印mysql专用表选项(例如engine)。

j9九游会登录的解决方案

将sql_mode的no_field_options属性去掉即可。

相关文档

网站地图