質問編集履歴

5

specテーブルに5番データ追加

2017/01/05 23:20

投稿

zico_teratail
zico_teratail

スコア907

test CHANGED
File without changes
test CHANGED
@@ -92,7 +92,11 @@
92
92
 
93
93
  (3, '跳ぶ'),
94
94
 
95
- (4, '握る');
95
+ (4, '握る'),
96
+
97
+ (5, '歩く');
98
+
99
+
96
100
 
97
101
 
98
102
 

4

specテーブルのcreateも修正

2017/01/05 23:19

投稿

zico_teratail
zico_teratail

スコア907

test CHANGED
File without changes
test CHANGED
@@ -76,7 +76,7 @@
76
76
 
77
77
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
78
78
 
79
- `spec` int(10) unsigned NOT NULL,
79
+ `spec` varchar(10) NOT NULL,
80
80
 
81
81
  PRIMARY KEY (`id`)
82
82
 

3

specテーブルへのinsertを修正

2017/01/05 16:13

投稿

zico_teratail
zico_teratail

スコア907

test CHANGED
File without changes
test CHANGED
@@ -86,13 +86,15 @@
86
86
 
87
87
  INSERT INTO `spec` (`id`, `spec`) VALUES
88
88
 
89
- (1, 0),
89
+ (1, '走る'),
90
90
 
91
- (2, 0),
91
+ (2, '投げる'),
92
92
 
93
- (3, 0),
93
+ (3, '跳ぶ'),
94
94
 
95
- (4, 0);
95
+ (4, '握る');
96
+
97
+
96
98
 
97
99
  ```
98
100
 

2

クエリも訂正

2017/01/05 16:12

投稿

zico_teratail
zico_teratail

スコア907

test CHANGED
File without changes
test CHANGED
@@ -128,9 +128,9 @@
128
128
 
129
129
  AND (
130
130
 
131
- a.spec_id =2
131
+ a.spec_id =5
132
132
 
133
- AND a.priority =5
133
+ AND a.priority =2
134
134
 
135
135
  )
136
136
 

1

テーブル定義修正

2017/01/05 14:12

投稿

zico_teratail
zico_teratail

スコア907

test CHANGED
File without changes
test CHANGED
@@ -34,7 +34,7 @@
34
34
 
35
35
  (1, 1, 1, 1),
36
36
 
37
- (2, 1, 2, 5),
37
+ (2, 1, 5, 2),
38
38
 
39
39
  (3, 2, 1, 1),
40
40