正在回答 回答被采纳积分+1
3回答
慕UI0732386
2019-09-01 19:18:57
用database执行脚本是出错了 [2019-09-01 19:14:14] Run F:\Mybatis案例源码\icake.sql [2019-09-01 19:14:14] Connecting to @localhost... [2019-09-01 19:14:14] Using batch mode (1000 insert/update/delete statements max) drop database if exists icake [2019-09-01 19:14:14] 2 row(s) affected in 38 ms create database icake [2019-09-01 19:14:14] 1 row(s) affected in 5 ms use icake [2019-09-01 19:14:14] 0 row(s) affected in 2 ms drop table if exists account [2019-09-01 19:14:14] 0 row(s) affected in 4 ms drop table if exists cake [2019-09-01 19:14:14] 0 row(s) affected in 2 ms drop table if exists catalog [2019-09-01 19:14:14] 0 row(s) affected in 9 ms create table account ( id int not null auto_increment, account varchar(20), password varchar(20), nick_name varchar(20), primary key (id) charset utf8 [2019-09-01 19:14:15] [42000][1064] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'charset utf8' at line 8 create table cake ( id int not null auto_increment, title varchar(20), cid int, image_path varchar(100), price double, taste varchar... [2019-09-01 19:14:15] 0 row(s) affected in 25 ms create table catalog ( id int not null auto_increment, title varchar(20), pid int, info varchar(100), primary key (id) ) [2019-09-01 19:14:15] 0 row(s) affected in 131 ms alter table cake add constraint FK_Reference_1 foreign key (cid) references catalog (id) on delete restrict on update restrict [2019-09-01 19:14:15] 0 row(s) affected in 27 ms alter table catalog add constraint FK_Reference_2 foreign key (pid) references catalog (id) on delete restrict on update restrict [2019-09-01 19:14:15] 0 row(s) affected in 22 ms insert into account(id,account,password,nick_name) values(10000,'admin','admin','管理员') ........ [2019-09-01 19:14:15] [HY000][1366] Incorrect string value: '\xE6\xB7\xB1\xE8\x89\xBE...' for column 'title' at row 1 [2019-09-01 19:14:15] Summary: 84 of 84 statements executed, 74 failed in 537 ms (7233 symbols in file)
3. Java 数据库开发与实战应用
- 参与学习 人
- 提交作业 357 份
- 解答问题 8016 个
本阶段将带你学习MySQL数据库,JDBC接口,MyBatis框架等,带你掌握的数据的存放和管理。
了解课程
恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧
0 星