添加字段:

alter table 表名 Add column 字段名 字段类型  默认值 AFTER 字段名 (在哪个字段后面添加)

例: alter table appstore_souapp_app_androidmarket Add column getPriceCurrency varchar(50) default null AFTER getPrice

修改字段:

alter table表名 change 字段名 新字段名 字段类型 默认值

例: alter table appstore_souapp_app_androidmarket change hasPrice hasPrice varchar(10)  null;

删除字段:

alter table 表名 drop column 字段名 例子: alter table appstore_souapp_app_androidmarket drop column getPriceCurrency

调整字段顺序:

alter table 表名 change 字段名 新字段名 字段类型 默认值 after 字段名(跳到哪个字段之后)

例: alter table appstore_souapp_app_androidmarket change getPriceCurrency getPriceCurrency varchar(50) default null AFTER getPrice

相关文章:

  • 2021-11-20
  • 2021-12-20
  • 2021-12-04
  • 2022-12-23
  • 2021-11-18
  • 2022-01-26
  • 2021-11-18
  • 2021-11-20
猜你喜欢
  • 2021-11-20
  • 2022-01-03
  • 2021-11-30
  • 2021-11-20
  • 2021-11-22
相关资源
相似解决方案