Verified Commit f5eb09ea authored by Kiryuu Sakuya's avatar Kiryuu Sakuya 🎵
Browse files

Fix example data

parent a21d4f51
...@@ -26,9 +26,9 @@ CREATE TABLE A ( ...@@ -26,9 +26,9 @@ CREATE TABLE A (
CREATE TABLE C ( CREATE TABLE C (
Cno INT NOT NULL COMMENT '电影公司编号', Cno INT NOT NULL COMMENT '电影公司编号',
Cname VARHAR(30) NOT NULL COMMENT '公司名称', Cname VARCHAR(30) NOT NULL COMMENT '公司名称',
Caddress VARCHAR(100) NOT NULL COMMENT '公司地址', Caddress VARCHAR(100) NOT NULL COMMENT '公司地址',
Ctel VARHAR(15) NOT NULL COMMENT '公司电话', Ctel VARCHAR(15) NOT NULL COMMENT '公司电话',
PRIMARY KEY (Cno) PRIMARY KEY (Cno)
); );
...@@ -66,52 +66,56 @@ CREATE TABLE R ( ...@@ -66,52 +66,56 @@ CREATE TABLE R (
INSERT INTO A ( INSERT INTO A (
Ano, Aname, Aaddress, Agender, Abirthday Ano, Aname, Aaddress, Agender, Abirthday
) VALUES ( ) VALUES (
10001, "Nicolas Cage", "1640 Riverside Drive, Hill Valley, California", Male, "1964-01-07" 10001, "Nicolas Cage", "1640 Riverside Drive, Hill Valley, California", "Male", "1964-01-07"
), ( ), (
10002, "Ellen Burstyn", "214 Caldwell Road, Buffalo, New York", Female, "1932-12-07" 10002, "Ellen Burstyn", "214 Caldwell Road, Buffalo, New York", "Female", "1932-12-07"
), ( ), (
10003, "Kate Beahan", "4725 Longview Avenue, Brooklyn, New York", Female, 10003, "Kate Beahan", "4725 Longview Avenue, Brooklyn, New York", "Female", "1974-10-12"
"1974-10-12"
), ( ), (
10004, "Leelee Sobieski", "2787 Larry Street, Milwaukee, Wisconsin", Female, "1983-06-10" 10004, "Leelee Sobieski", "2787 Larry Street, Milwaukee, Wisconsin", "Female", "1983-06-10"
), ( ), (
10005, "赵薇", "北京市海淀区西土城路4号", Female, "1976-03-12" 10005, "赵薇", "北京市海淀区西土城路4号", "Female", "1976-03-12"
), ( ), (
10006, "陈坤", "重庆市巴南区龙庭街5号城南未来三期1-2-5号", Male, "1976-02-04" 10006, "陈坤", "重庆市巴南区龙庭街5号城南未来三期1-2-5号", "Male", "1976-02-04"
), ( ), (
10007, "胡军", "北京市东城区东棉花胡同39号", Male, "1968-03-18" 10007, "胡军", "北京市东城区东棉花胡同39号", "Male", "1968-03-18"
), ( ), (
10008, "房祖名", "香港湾仔皇后大道东281号", Male, "1982-12-03" 10008, "房祖名", "香港湾仔皇后大道东281号", "Male", "1982-12-03"
), ( ), (
10009, "Joaquin Phoenix", "3856 Maple Avenue, Stockton, California", Male, "1974-10-28" 10009, "Joaquin Phoenix", "3856 Maple Avenue, Stockton, California", "Male", "1974-10-28"
), ( ), (
10010, "Robert De Niro", "1276 Oak Drive, Ellenburg Depot, New York", Male, "1943-08-17" 10010, "Robert De Niro", "1276 Oak Drive, Ellenburg Depot, New York", "Male", "1943-08-17"
), ( ), (
10011, "Zazie Beetz", "Brandenburgische Straße 75, Berlin Pankow, Berlin", Female, "1991-05-25" 10011, "Zazie Beetz", "Brandenburgische Straße 75, Berlin Pankow, Berlin", "Female", "1991-05-25"
), ( ), (
10012, "Frances Conroy", "626 College Street, Atlanta, Georgia", Female, "1953-11-13" 10012, "Frances Conroy", "626 College Street, Atlanta, Georgia", "Female", "1953-11-13"
); );
INSERT INTO C ( INSERT INTO C (
Cno, Cname, Caddress, Ctel Cno, Cname, Caddress, Ctel
) VALUES ( ) VALUES (
20001, "Warner Bros", "Burbank, US (HQ) 4000 Warner Blvd.", "+1818954 3000", 20001, "Warner Bros", 'Burbank, US (HQ) 4000 Warner Blvd.', "+18189543000"
), (
20002, "星光国际传媒(集团)有限公司", "北京市朝阳区建国路112号4层A1008", "+8601085970999" 20002, "星光国际传媒(集团)有限公司", "北京市朝阳区建国路112号4层A1008", "+8601085970999"
); );
INSERT INTO M ( INSERT INTO M (
Mno, Mname, Mlength, Myear, Cno Mno, Mname, Mlength, Myear, Cno
) VALUES ( ) VALUES (
30001, "The Wicker Man", "102", "2006", "0450345", 30001, "The Wicker Man", "102", "2006", "20001"
30002, "花木兰", "114", "2009", "1308138", ), (
30003, "Joker", "122", "2019", "7286456" 30002, "花木兰", "114", "2009", "20002"
), (
30003, "Joker", "122", "2019", "20001"
); );
INSERT INTO I ( INSERT INTO I (
Ino, Mno, Itime, Iprice Ino, Mno, Itime, Iprice
) VALUES ( ) VALUES (
40001, 30001, "2006-09-01", "85.33", 40001, 30001, "2006-09-01", "85.33"
40002, 30002, "2009-11-27", "36", ), (
40002, 30002, "2009-11-27", "36"
), (
40003, 30003, "2019-10-04", "132.65" 40003, 30003, "2019-10-04", "132.65"
); );
...@@ -151,7 +155,7 @@ INSERT INTO R ( ...@@ -151,7 +155,7 @@ INSERT INTO R (
### 1. 用 SQL 查询所有 `Warner Bros` 电影公司制作的电影名称和电影主演的姓名,主演要求在电影中出现的时间大于 40 分钟 ### 1. 用 SQL 查询所有 `Warner Bros` 电影公司制作的电影名称和电影主演的姓名,主演要求在电影中出现的时间大于 40 分钟
```mysql ```mysql
SELECT SELECT FROM WHERE
``` ```
### 2. 用 SQL 查询所有上映时间在 2006-09-01 和 2006-10-01 之间的由演员 `Nicolas Cage` 所演的电影的名称 ### 2. 用 SQL 查询所有上映时间在 2006-09-01 和 2006-10-01 之间的由演员 `Nicolas Cage` 所演的电影的名称
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment