mysql怎么在數據庫里添加表
1 回答
鳳凰求蠱
TA貢獻1825條經驗 獲得超4個贊
#創建customer表:
create table customers(
id int not null auto_increment,
name char(20) not null,
address char(50) null,
city char(50) null,
age int not null,
love char(50) not null default 'No habbit',
primary key(id)
)engine=InnoDB;
#SELECT last_insert_id();這個函數可以獲得返回最后一個auto_increment值.
#默認值:default 'No habbit',
#引擎類型,多為engine = InnoDB,如果省略了engine=語句,則使用默認的引擎(MyISAM)。
添加回答
舉報
0/150
提交
取消
