create table class ( code ) primary Key, name ) );
create table student ( code ) primary Key, name ), sex bit, age int, class ), foreign Key (class) references class(code) );
create table kecheng ( code ) primary Key, name ) );
create table teacher ( code ) primary Key, name ) );
create table chengji ( ids int auto_increment primary Key, scode ), kcode ), degree float, foreign Key (scode) references student(code), foreign Key (kcode) references kecheng(code) );
create table tkecheng ( ids int auto_increment primary Key, tcode ), kcode ), foreign Key (tcode) references teacher(code), foreign Key (kcode) references kecheng(code) );