表РCreate database example;РUse example;РCrate table student(num int(10) not null unique primary key,Р Name varchar(20) not null,Р Sex varchar(4) not null,Р Birthday datetime,Р Address varchar(50)Р );РCreate grade (id int(10) not null unique primary key auto_increment,Р Course varchar(10) not null,Р S_num int(10) not null,Р Grade varchar(4)Р Constraint grade_fk foreign key(s_num) reference student(num)Р );РDesc student;РShow create table grade \G;РAlter table grade modify course varchar(20);РAlter table grade modify s_num int(10) after id;РAlter table grade change grade score varchar(4);РAlter table grade drop foreign key grade_fk;РAlter table grade engine=myisam;РAlter table student drop address;РAlter table student add phone int(10);РAlter table grade rename gradeinfo;РDrop table student;