· 8 years ago · Aug 07, 2018, 08:54 AM
1-----------------------------------------------
2 file: /usr/bin/phake
3 args: db:build
4 date: Wed, 04 Aug 10 22:22:33 +0200
5 -----------------------------------------------
6[3.83 ms] -- loading library: data --
7[4.51 ms] Library_Data::__construct() called
8[1435.16 ms] Query_MySQLi::__construct() called
9[1435.19 ms] Query_MySQLi::query() called
10 -- query executed in 0.11 ms.
11 -- SQL: SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 --
12[1435.31 ms] Query_MySQLi::__destruct() called
13[1435.35 ms] Query_MySQLi::__construct() called
14[1435.36 ms] Query_MySQLi::query() called
15 -- query executed in 0.06 ms.
16 -- SQL:
17SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 --
18[1435.43 ms] Query_MySQLi::__destruct() called
19[1435.46 ms] Query_MySQLi::__construct() called
20[1435.47 ms] Query_MySQLi::query() called
21 -- query executed in 0.06 ms.
22 -- SQL:
23SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL' --
24[1435.54 ms] Query_MySQLi::__destruct() called
25[1435.57 ms] Query_MySQLi::__construct() called
26[1435.58 ms] Query_MySQLi::query() called
27 -- query executed in 0.07 ms.
28 -- SQL:
29
30CREATE SCHEMA IF NOT EXISTS `vo20` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci --
31[1435.66 ms] Query_MySQLi::__destruct() called
32[1435.70 ms] Query_MySQLi::__construct() called
33[1435.71 ms] Query_MySQLi::query() called
34 -- query executed in 199.71 ms.
35 -- SQL:
36
37-- -----------------------------------------------------
38-- Table `vo20`.`users`
39-- -----------------------------------------------------
40CREATE TABLE IF NOT EXISTS `vo20`.`users` (
41 `id` INT NOT NULL AUTO_INCREMENT ,
42 `username` VARCHAR(45) NOT NULL ,
43 `password` VARCHAR(40) NOT NULL ,
44 `name` VARCHAR(255) NOT NULL ,
45 `role` INT NULL ,
46 PRIMARY KEY (`id`) )
47ENGINE = InnoDB
48DEFAULT CHARACTER SET = utf8 --
49[1635.51 ms] Query_MySQLi::__destruct() called
50[1635.68 ms] Query_MySQLi::__construct() called
51[1635.71 ms] Query_MySQLi::query() called
52 -- query executed in 112.24 ms.
53 -- SQL:
54
55
56-- -----------------------------------------------------
57-- Table `vo20`.`courses`
58-- -----------------------------------------------------
59CREATE TABLE IF NOT EXISTS `vo20`.`courses` (
60 `id` INT NOT NULL AUTO_INCREMENT ,
61 `name` VARCHAR(45) NOT NULL ,
62 PRIMARY KEY (`id`) )
63ENGINE = InnoDB
64DEFAULT CHARACTER SET = utf8 --
65[1748.04 ms] Query_MySQLi::__destruct() called
66[1748.20 ms] Query_MySQLi::__construct() called
67[1748.23 ms] Query_MySQLi::query() called
68 -- query executed in 101.14 ms.
69 -- SQL:
70
71
72-- -----------------------------------------------------
73-- Table `vo20`.`languages`
74-- -----------------------------------------------------
75CREATE TABLE IF NOT EXISTS `vo20`.`languages` (
76 `id` INT NOT NULL ,
77 `name` VARCHAR(45) NOT NULL ,
78 `code` VARCHAR(5) NOT NULL ,
79 PRIMARY KEY (`id`) )
80ENGINE = InnoDB
81DEFAULT CHARACTER SET = utf8 --
82[1849.45 ms] Query_MySQLi::__destruct() called
83[1849.70 ms] Query_MySQLi::__construct() called
84[1849.73 ms] Query_MySQLi::query() called
85 -- query executed in 170.38 ms.
86 -- SQL:
87
88
89-- -----------------------------------------------------
90-- Table `vo20`.`exams`
91-- -----------------------------------------------------
92CREATE TABLE IF NOT EXISTS `vo20`.`exams` (
93 `id` INT NOT NULL AUTO_INCREMENT ,
94 `user_id` INT NOT NULL ,
95 `course_id` INT NOT NULL ,
96 `language_id` INT NOT NULL ,
97 `title` VARCHAR(255) NOT NULL ,
98 `created` DATETIME NOT NULL ,
99 `modified` DATETIME NOT NULL ,
100 PRIMARY KEY (`id`) ,
101 INDEX `fk_exams_users` (`user_id` ASC) ,
102 INDEX `fk_exams_courses` (`course_id` ASC) ,
103 INDEX `fk_exams_languages` (`language_id` ASC) ,
104 CONSTRAINT `fk_tests_users`
105 FOREIGN KEY (`user_id` )
106 REFERENCES `vo20`.`users` (`id` )
107 ON DELETE NO ACTION
108 ON UPDATE NO ACTION,
109 CONSTRAINT `fk_tests_courses`
110 FOREIGN KEY (`course_id` )
111 REFERENCES `vo20`.`courses` (`id` )
112 ON DELETE NO ACTION
113 ON UPDATE NO ACTION,
114 CONSTRAINT `fk_exams_languages`
115 FOREIGN KEY (`language_id` )
116 REFERENCES `vo20`.`languages` (`id` )
117 ON DELETE NO ACTION
118 ON UPDATE NO ACTION)
119ENGINE = InnoDB
120DEFAULT CHARACTER SET = utf8 --
121[2020.19 ms] Query_MySQLi::__destruct() called
122[2020.38 ms] Query_MySQLi::__construct() called
123[2020.41 ms] Query_MySQLi::query() called
124 -- query executed in 112.08 ms.
125 -- SQL:
126
127
128-- -----------------------------------------------------
129-- Table `vo20`.`pages`
130-- -----------------------------------------------------
131CREATE TABLE IF NOT EXISTS `vo20`.`pages` (
132 `id` INT NOT NULL AUTO_INCREMENT ,
133 `exam_id` INT NOT NULL ,
134 `title` VARCHAR(255) NOT NULL ,
135 `position` INT NOT NULL ,
136 PRIMARY KEY (`id`) ,
137 INDEX `fk_pages_exams` (`exam_id` ASC) ,
138 CONSTRAINT `fk_pages_tests`
139 FOREIGN KEY (`exam_id` )
140 REFERENCES `vo20`.`exams` (`id` )
141 ON DELETE NO ACTION
142 ON UPDATE NO ACTION)
143ENGINE = InnoDB
144DEFAULT CHARACTER SET = utf8 --
145[2132.58 ms] Query_MySQLi::__destruct() called
146[2132.74 ms] Query_MySQLi::__construct() called
147[2132.77 ms] Query_MySQLi::query() called
148 -- query executed in 101.08 ms.
149 -- SQL:
150
151
152-- -----------------------------------------------------
153-- Table `vo20`.`question_types`
154-- -----------------------------------------------------
155CREATE TABLE IF NOT EXISTS `vo20`.`question_types` (
156 `id` INT NOT NULL AUTO_INCREMENT ,
157 `name` VARCHAR(45) NOT NULL ,
158 PRIMARY KEY (`id`) )
159ENGINE = InnoDB
160DEFAULT CHARACTER SET = utf8 --
161[2233.94 ms] Query_MySQLi::__destruct() called
162[2234.18 ms] Query_MySQLi::__construct() called
163[2234.21 ms] Query_MySQLi::query() called
164 -- query executed in 102.07 ms.
165 -- SQL:
166
167
168-- -----------------------------------------------------
169-- Table `vo20`.`questions`
170-- -----------------------------------------------------
171CREATE TABLE IF NOT EXISTS `vo20`.`questions` (
172 `id` INT NOT NULL AUTO_INCREMENT ,
173 `parent_id` INT NULL ,
174 `page_id` INT NOT NULL ,
175 `type_id` INT NOT NULL ,
176 `title` VARCHAR(255) NOT NULL ,
177 `text` MEDIUMTEXT NOT NULL ,
178 `answer` MEDIUMTEXT NULL ,
179 `created` DATETIME NOT NULL ,
180 `modified` DATETIME NOT NULL ,
181 PRIMARY KEY (`id`) ,
182 INDEX `fk_questions_pages` (`page_id` ASC) ,
183 INDEX `fk_questions_types` (`type_id` ASC) ,
184 INDEX `fk_questions_questions` (`id` ASC) ,
185 CONSTRAINT `fk_questions_pages`
186 FOREIGN KEY (`page_id` )
187 REFERENCES `vo20`.`pages` (`id` )
188 ON DELETE NO ACTION
189 ON UPDATE NO ACTION,
190 CONSTRAINT `fk_questions_types`
191 FOREIGN KEY (`type_id` )
192 REFERENCES `vo20`.`question_types` (`id` )
193 ON DELETE NO ACTION
194 ON UPDATE NO ACTION,
195 CONSTRAINT `fk_questions_questions`
196 FOREIGN KEY (`id` )
197 REFERENCES `vo20`.`questions` (`parent_id` )
198 ON DELETE NO ACTION
199 ON UPDATE NO ACTION)
200ENGINE = InnoDB
201DEFAULT CHARACTER SET = utf8 --
202[2336.34 ms] Query_MySQLi::query(): MySQLi error!
203 -- #1005: Can't create table 'vo20.questions' (errno: 150) --
204 -- SQL:
205
206
207-- -----------------------------------------------------
208-- Table `vo20`.`questions`
209-- -----------------------------------------------------
210CREATE TABLE IF NOT EXISTS `vo20`.`questions` (
211 `id` INT NOT NULL AUTO_INCREMENT ,
212 `parent_id` INT NULL ,
213 `page_id` INT NOT NULL ,
214 `type_id` INT NOT NULL ,
215 `title` VARCHAR(255) NOT NULL ,
216 `text` MEDIUMTEXT NOT NULL ,
217 `answer` MEDIUMTEXT NULL ,
218 `created` DATETIME NOT NULL ,
219 `modified` DATETIME NOT NULL ,
220 PRIMARY KEY (`id`) ,
221 INDEX `fk_questions_pages` (`page_id` ASC) ,
222 INDEX `fk_questions_types` (`type_id` ASC) ,
223 INDEX `fk_questions_questions` (`id` ASC) ,
224 CONSTRAINT `fk_questions_pages`
225 FOREIGN KEY (`page_id` )
226 REFERENCES `vo20`.`pages` (`id` )
227 ON DELETE NO ACTION
228 ON UPDATE NO ACTION,
229 CONSTRAINT `fk_questions_types`
230 FOREIGN KEY (`type_id` )
231 REFERENCES `vo20`.`question_types` (`id` )
232 ON DELETE NO ACTION
233 ON UPDATE NO ACTION,
234 CONSTRAINT `fk_questions_questions`
235 FOREIGN KEY (`id` )
236 REFERENCES `vo20`.`questions` (`parent_id` )
237 ON DELETE NO ACTION
238 ON UPDATE NO ACTION)
239ENGINE = InnoDB
240DEFAULT CHARACTER SET = utf8 --
241[2336.44 ms] Query_MySQLi::__destruct() called
242[2336.62 ms] Query_MySQLi::__construct() called
243[2336.65 ms] Query_MySQLi::query() called
244 -- query executed in 100.69 ms.
245 -- SQL:
246
247
248-- -----------------------------------------------------
249-- Table `vo20`.`variables`
250-- -----------------------------------------------------
251CREATE TABLE IF NOT EXISTS `vo20`.`variables` (
252 `id` INT NOT NULL AUTO_INCREMENT ,
253 `page_id` INT NOT NULL ,
254 `name` VARCHAR(45) NOT NULL ,
255 `value` VARCHAR(255) NOT NULL ,
256 PRIMARY KEY (`id`) ,
257 INDEX `fk_variables_pages` (`page_id` ASC) ,
258 CONSTRAINT `fk_variables_pages`
259 FOREIGN KEY (`page_id` )
260 REFERENCES `vo20`.`pages` (`id` )
261 ON DELETE NO ACTION
262 ON UPDATE NO ACTION)
263ENGINE = InnoDB
264DEFAULT CHARACTER SET = utf8 --
265[2437.41 ms] Query_MySQLi::__destruct() called
266[2437.58 ms] Query_MySQLi::__construct() called
267[2437.61 ms] Query_MySQLi::query() called
268 -- query executed in 89.92 ms.
269 -- SQL:
270
271
272-- -----------------------------------------------------
273-- Table `vo20`.`schools`
274-- -----------------------------------------------------
275CREATE TABLE IF NOT EXISTS `vo20`.`schools` (
276 `id` INT NOT NULL ,
277 `name` VARCHAR(45) NOT NULL ,
278 `location` VARCHAR(255) NOT NULL ,
279 PRIMARY KEY (`id`) )
280ENGINE = InnoDB
281DEFAULT CHARACTER SET = utf8 --
282[2527.61 ms] Query_MySQLi::__destruct() called
283[2527.79 ms] Query_MySQLi::__construct() called
284[2527.82 ms] Query_MySQLi::query() called
285 -- query executed in 90.08 ms.
286 -- SQL:
287
288
289-- -----------------------------------------------------
290-- Table `vo20`.`groups`
291-- -----------------------------------------------------
292CREATE TABLE IF NOT EXISTS `vo20`.`groups` (
293 `id` INT NOT NULL ,
294 `school_id` INT NOT NULL ,
295 `name` VARCHAR(255) NOT NULL ,
296 PRIMARY KEY (`id`, `school_id`) ,
297 INDEX `fk_groups_schools` (`school_id` ASC) ,
298 CONSTRAINT `fk_groups_schools`
299 FOREIGN KEY (`school_id` )
300 REFERENCES `vo20`.`schools` (`id` )
301 ON DELETE NO ACTION
302 ON UPDATE NO ACTION)
303ENGINE = InnoDB
304DEFAULT CHARACTER SET = utf8 --
305[2617.98 ms] Query_MySQLi::__destruct() called
306[2618.19 ms] Query_MySQLi::__construct() called
307[2618.22 ms] Query_MySQLi::query() called
308 -- query executed in 125.62 ms.
309 -- SQL:
310
311
312-- -----------------------------------------------------
313-- Table `vo20`.`groups_users`
314-- -----------------------------------------------------
315CREATE TABLE IF NOT EXISTS `vo20`.`groups_users` (
316 `group_id` INT NOT NULL ,
317 `user_id` INT NOT NULL ,
318 PRIMARY KEY (`group_id`, `user_id`) ,
319 INDEX `fk_groups_users_groups` (`group_id` ASC) ,
320 INDEX `fk_groups_users_users` (`user_id` ASC) ,
321 CONSTRAINT `fk_groups_users_groups`
322 FOREIGN KEY (`group_id` )
323 REFERENCES `vo20`.`groups` (`id` )
324 ON DELETE NO ACTION
325 ON UPDATE NO ACTION,
326 CONSTRAINT `fk_groups_users_users`
327 FOREIGN KEY (`user_id` )
328 REFERENCES `vo20`.`users` (`id` )
329 ON DELETE NO ACTION
330 ON UPDATE NO ACTION)
331ENGINE = InnoDB
332DEFAULT CHARACTER SET = utf8 --
333[2743.92 ms] Query_MySQLi::__destruct() called
334[2744.10 ms] Query_MySQLi::__construct() called
335[2744.14 ms] Query_MySQLi::query() called
336 -- query executed in 101.02 ms.
337 -- SQL:
338
339
340-- -----------------------------------------------------
341-- Table `vo20`.`variable_values`
342-- -----------------------------------------------------
343CREATE TABLE IF NOT EXISTS `vo20`.`variable_values` (
344 `id` INT NOT NULL ,
345 `variable_id` INT NOT NULL ,
346 `value` VARCHAR(255) NOT NULL ,
347 PRIMARY KEY (`id`) ,
348 INDEX `fk_variable_values_variables` (`variable_id` ASC) ,
349 CONSTRAINT `fk_variable_values_variables`
350 FOREIGN KEY (`variable_id` )
351 REFERENCES `vo20`.`variables` (`id` )
352 ON DELETE NO ACTION
353 ON UPDATE NO ACTION)
354ENGINE = InnoDB
355DEFAULT CHARACTER SET = utf8 --
356[2845.24 ms] Query_MySQLi::__destruct() called
357[2845.46 ms] Query_MySQLi::__construct() called
358[2845.49 ms] Query_MySQLi::query() called
359 -- query executed in 123.65 ms.
360 -- SQL:
361
362
363-- -----------------------------------------------------
364-- Table `vo20`.`answers`
365-- -----------------------------------------------------
366CREATE TABLE IF NOT EXISTS `vo20`.`answers` (
367 `id` INT NOT NULL ,
368 `question_id` INT NOT NULL ,
369 `user_id` INT NOT NULL ,
370 `question` MEDIUMTEXT NOT NULL ,
371 `text` MEDIUMTEXT NULL ,
372 `locked` TINYINT(1) NOT NULL DEFAULT 0 ,
373 PRIMARY KEY (`id`) ,
374 INDEX `fk_answers_questions` (`question_id` ASC) ,
375 INDEX `fk_answers_users` (`user_id` ASC) ,
376 CONSTRAINT `fk_answers_questions`
377 FOREIGN KEY (`question_id` )
378 REFERENCES `vo20`.`questions` (`id` )
379 ON DELETE NO ACTION
380 ON UPDATE NO ACTION,
381 CONSTRAINT `fk_answers_users`
382 FOREIGN KEY (`user_id` )
383 REFERENCES `vo20`.`users` (`id` )
384 ON DELETE NO ACTION
385 ON UPDATE NO ACTION)
386ENGINE = InnoDB
387DEFAULT CHARACTER SET = utf8 --
388[2969.22 ms] Query_MySQLi::__destruct() called
389[2969.43 ms] Query_MySQLi::__construct() called
390[2969.46 ms] Query_MySQLi::query() called
391 -- query executed in 123.58 ms.
392 -- SQL:
393
394
395-- -----------------------------------------------------
396-- Table `vo20`.`assignments`
397-- -----------------------------------------------------
398CREATE TABLE IF NOT EXISTS `vo20`.`assignments` (
399 `id` INT NOT NULL ,
400 `users_id` INT NOT NULL ,
401 `exam_id` INT NOT NULL ,
402 `start` DATETIME NOT NULL ,
403 `end` DATETIME NULL ,
404 `acceptation` DATETIME NULL ,
405 PRIMARY KEY (`id`) ,
406 INDEX `fk_assignments_users` (`users_id` ASC) ,
407 INDEX `fk_assignments_exams` (`exam_id` ASC) ,
408 CONSTRAINT `fk_assignments_users`
409 FOREIGN KEY (`users_id` )
410 REFERENCES `vo20`.`users` (`id` )
411 ON DELETE NO ACTION
412 ON UPDATE NO ACTION,
413 CONSTRAINT `fk_assignments_exams`
414 FOREIGN KEY (`exam_id` )
415 REFERENCES `vo20`.`exams` (`id` )
416 ON DELETE NO ACTION
417 ON UPDATE NO ACTION)
418ENGINE = InnoDB
419DEFAULT CHARACTER SET = utf8 --
420[3093.12 ms] Query_MySQLi::__destruct() called
421[3093.32 ms] Query_MySQLi::__construct() called
422[3093.35 ms] Query_MySQLi::query() called
423 -- query executed in 123.57 ms.
424 -- SQL:
425
426
427-- -----------------------------------------------------
428-- Table `vo20`.`notes`
429-- -----------------------------------------------------
430CREATE TABLE IF NOT EXISTS `vo20`.`notes` (
431 `id` INT NOT NULL ,
432 `answer_id` INT NOT NULL ,
433 `user_id` INT NOT NULL ,
434 `text` MEDIUMTEXT NOT NULL ,
435 PRIMARY KEY (`id`) ,
436 INDEX `fk_notes_users` (`user_id` ASC) ,
437 INDEX `fk_notes_answers` (`answer_id` ASC) ,
438 CONSTRAINT `fk_notes_users`
439 FOREIGN KEY (`user_id` )
440 REFERENCES `vo20`.`users` (`id` )
441 ON DELETE NO ACTION
442 ON UPDATE NO ACTION,
443 CONSTRAINT `fk_notes_answers`
444 FOREIGN KEY (`answer_id` )
445 REFERENCES `vo20`.`answers` (`id` )
446 ON DELETE NO ACTION
447 ON UPDATE NO ACTION)
448ENGINE = InnoDB
449DEFAULT CHARACTER SET = utf8 --
450[3217.00 ms] Query_MySQLi::__destruct() called
451[3217.19 ms] Query_MySQLi::__construct() called
452[3217.22 ms] Query_MySQLi::query() called
453 -- query executed in 89.99 ms.
454 -- SQL:
455
456
457-- -----------------------------------------------------
458-- Table `vo20`.`choices`
459-- -----------------------------------------------------
460CREATE TABLE IF NOT EXISTS `vo20`.`choices` (
461 `id` INT NOT NULL ,
462 `question_id` INT NOT NULL ,
463 `value` VARCHAR(255) NOT NULL ,
464 PRIMARY KEY (`id`) ,
465 INDEX `fk_choices_questions` (`question_id` ASC) ,
466 CONSTRAINT `fk_choices_questions`
467 FOREIGN KEY (`question_id` )
468 REFERENCES `vo20`.`questions` (`id` )
469 ON DELETE NO ACTION
470 ON UPDATE NO ACTION)
471ENGINE = InnoDB
472DEFAULT CHARACTER SET = utf8 --
473[3307.29 ms] Query_MySQLi::__destruct() called
474[3307.51 ms] Query_MySQLi::__construct() called
475[3307.54 ms] Query_MySQLi::query() called
476 -- query executed in 89.95 ms.
477 -- SQL:
478
479
480-- -----------------------------------------------------
481-- Table `vo20`.`sessions`
482-- -----------------------------------------------------
483CREATE TABLE IF NOT EXISTS `vo20`.`sessions` (
484 `id` INT NOT NULL ,
485 `user_id` INT NOT NULL ,
486 `ip` INT(11) NOT NULL ,
487 `hash` VARCHAR(40) NOT NULL ,
488 `page` VARCHAR(255) NOT NULL ,
489 `expires` DATETIME NOT NULL ,
490 `created` DATETIME NOT NULL ,
491 `modified` DATETIME NOT NULL ,
492 PRIMARY KEY (`id`) ,
493 INDEX `fk_sessions_users1` (`user_id` ASC) ,
494 CONSTRAINT `fk_sessions_users1`
495 FOREIGN KEY (`user_id` )
496 REFERENCES `vo20`.`users` (`id` )
497 ON DELETE NO ACTION
498 ON UPDATE NO ACTION)
499ENGINE = InnoDB --
500[3397.57 ms] Query_MySQLi::__destruct() called
501[3397.70 ms] Query_MySQLi::__construct() called
502[3397.73 ms] Query_MySQLi::query() called
503 -- query executed in 0.22 ms.
504 -- SQL:
505
506
507
508SET SQL_MODE=@OLD_SQL_MODE --
509[3397.99 ms] Query_MySQLi::__destruct() called
510[3398.08 ms] Query_MySQLi::__construct() called
511[3398.10 ms] Query_MySQLi::query() called
512 -- query executed in 0.17 ms.
513 -- SQL:
514SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS --
515[3398.31 ms] Query_MySQLi::__destruct() called
516[3398.40 ms] Query_MySQLi::__construct() called
517[3398.43 ms] Query_MySQLi::query() called
518 -- query executed in 0.16 ms.
519 -- SQL:
520SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS --
521[3398.63 ms] Query_MySQLi::__destruct() called
522[3452.74 ms] Boot::__destruct() called
523[3452.97 ms] Controller::__destruct() called
524[3453.06 ms] Library_Data::__destruct() called