SQL code:
SET NAMES 'gb2312'
drop table if exists t_course;
create table t_course(
id int(11) not null auto_increment,
name varchar(50) default null,
primary key(id)
)ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 ROW_FORMAT=COMPRESSED;
#set names 'gbk';
insert into t_course values (1,'java');
insert into t_course values (2,'.Net');
insert into t_course values (3,'PHP');
insert into t_course values (4,'¿ò¼Ü');
drop table if exists t_subject;
create table t_subject(
id int(11) not null auto_increment,
name varchar(50) default null,
course_id int(11) default null,
primary key(id)
)DEFAULT CHARSET=utf8;
insert into t_subject values (1,'jsp',1);
insert into t_subject values (2,'servlet',1);
insert into t_subject values (3,'struts',1);
insert into t_subject values (4,'c#',2);
insert into t_subject values (5,'ASP.NET',2);
insert into t_subject values (6,'VB.NET',2);
insert into t_subject values (7,'php',3);
insert into t_subject values (8,'mysql',3);
insert into t_subject values (9,'hibernate¿ò¼Ü',4);
insert into t_subject values (10,'spring¿ò¼Ü',4);
µ¼ÈëÕý³££¬¿ÉÊDzéѯʱȫÏÔʾ£º
Query OK, 1 row affected (0.02 sec)
Query OK, 1 row affected (0.00 sec)
Query OK, 1 row affected (0.01 sec)
Query OK, 1 row affected (0.00 sec)
ERROR 1
ÎÒÓÐÒ»¸öjava»·¾³ÏµijÌÐò£¬ÔÚ±¾»úÔËÐÐÕý³££¬µ«·¢²¼µ½ÍøµÄÐéÄâÖ÷»úʱ²»ÄÜÁ¬½ÓÊý¾Ý¿âÁ¬½Ó³Ø
jdk 1.6 tomcat6.0.18 mysql5 mysqljdbc5.1.5
ÐéÄâÖ÷»úµÄ¼¼ÊõÈËԱ˵£¬Ö»ÄÜÅäÖþÖÓòµÄÊý¾Ý¿âÁ¬½Ó³Ø£¬Ò²¾ÍÊÇÔÚM ......