1、添加字段
ALTER TABLE `mall_order` ADD COLUMN `ip` varchar(20) NOT NULL DEFAULT '' COMMENT '购买人IP';
2、添加索引
alter table `tableName` add index `idx_name` (`columnName1`,`columnName2`)
create index `idx_name` on `tableName` (`columnName1`,`columnName2`)
3、添加主键
alter table `tableName` add primary key(`columnName`)