Chinaunix首页 | 论坛 | 博客
  • 博客访问: 250731
  • 博文数量: 34
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 961
  • 用 户 组: 普通用户
  • 注册时间: 2013-07-11 17:19
个人简介

没有最好的语言,只有最适合的语言。

文章分类

全部博文(34)

文章存档

2016年(2)

2013年(32)

我的朋友

分类: Mysql/postgreSQL

2013-07-11 18:59:53

Alter table tb change id id int(10) not null auto_increment=1;//有问题

mysql> alter table newcar change id id int(11) not null auto-increment;//有问题

mysql> alter table newcar change id id int(11) not null AUTO_INCREMENT=1;//有问题

修改:alter table newcar change id id int(11) not null AUTO_INCREMENT;

 

删除

Alter table tb change id id int(10);//删除自增长

Alter table tb drop primary key;//删除主建

阅读(1922) | 评论(0) | 转发(1) |
给主人留下些什么吧!~~